KGy SOFT

KGySoft.ComponentModel Namespace

KGy SOFT Core Libraries Help
Contains TypeConverter implementations for several types as well as base classes for different kind of business object models (such as the ModelBase class), and types for command binding, which provide a technology-agnostic approach for binding events to commands (see ICommand interface for details and examples).
Classes

  ClassDescription
Public classAddingNewEventArgsT
Provides data for the FastBindingList<T>.AddingNew event.
Public classBinaryTypeConverter
Provides a type converter to convert any Object to and from base64 encoded String or byte array representations.
Public classCommand
Contains extension methods for the ICommand and INotifyPropertyChanged types as well as a couple of property binding creation methods for any object.
See the Remarks section of the ICommand interface for details and examples about commands.
Public classCommandBindingsCollection
Represents a collection of command bindings. If a component or control uses events, then this class can be used to create and hold the event bindings, regardless of any used technology. When this class is disposed, all of the internally subscribed events will be released at once. Removed and replaced bindings will also be disposed.
See the Remarks section of the ICommand interface for details and examples about commands.
Public classCommandState
Represents the states of a command for a specific command binding.
See the ICommandState interface for details and the Remarks section of ICommand for some examples.
Public classEditableObjectBase
Represents an object with editing capabilities by adding ICanEdit implementation to the PersistableObjectBase class. Starting an edit session saves a snapshot of the stored properties, which can be either applied or reverted. Saving and restoring properties works for properties set through the IPersistableObject implementation and the ObservableObjectBase.Set method.
See the Remarks section for details.
Public classEncodingConverter
Provides a type converter to convert Encoding instances to and from String or Int32 representations.
Public classExecuteCommandEventArgs
Provides data for the ICommandBinding.Executing and ICommandBinding.Executed events.
Public classFastBindingListT
Provides a generic list that is able to notify its consumer about changes and supports data binding.
See the Remarks section for the differences compared to the BindingListT class.
Public classFlagsEnumConverter
By extending the EnumConverter, this class provides a type converter for flags Enum instances (not necessarily but typically marked by FlagsAttribute) by providing Boolean properties for each flags in the specific Enum type.
Public classModelBase
Provides a base object for model classes or business objects, which can validate their state, have undo/redo capability and can support committable/revertible editing.
See the Remarks section for details.
Public classNullStateUpdater
Provides an updater, which does not synchronize command state changes to any command source. Adding this updater to a ICommandBinding ensures that no other updater will be called, which are added after the NullStateUpdater. You can add this updater to a ICommandBinding first to disable any other possibly added updater.
Public classObservableBindingListT
Public classObservableObjectBase
Provides a base class for component model classes, which can notify their consumer about property changes.
See the Remarks section for details and examples.
Public classPersistableObjectBase
Provides a base class for component model classes, which provide a public access to their internal property storage located in the ObservableObjectBase base class by implementing also the IPersistableObject interface.
For details see the Remarks section.
Public classPropertyChangedEventArgsExtensions
Extension methods for the PropertyChangedEventArgs type.
Public classPropertyChangedExtendedEventArgs
Represents a PropertyChangedEventArgs with property value. The actual type of the event argument of the ObservableObjectBase.PropertyChanged event is PropertyChangedExtendedEventArgs.
Public classPropertyCommandStateUpdater
Provides an updater for the ICommandState entries, which treats state entries as properties on the command sources. When a state entry in the ICommandState changes, this updater tries to set the properties of the same name on the bound sources. For example, if a command represents a UI action bound to a menu item or a button (or both), then changing the Enabled property changes the Enabled property of the bound sources as well. You can adjust the text, shortcuts, associated image, checked state, etc. of the sources similarly.
See the Remarks section for details.
Public classSimpleCommand
Represents a command, which is unaware of its triggering sources and has no bound targets.
See the Remarks section of the ICommand interface for details and examples about commands.
Public classSortableBindingListT
Provides a sortable generic list that is able to notify its consumer about changes and supports data binding.
See the Remarks section for details.
Public classSourceAwareCommandTEventArgs
Represents a command, which is aware of its triggering sources and has no bound targets.
See the Remarks section of the ICommand interface for details and examples about commands.
Public classSourceAwareTargetedCommandTEventArgs, TTarget
Represents a command, which is aware of its triggering sources and has one or more bound targets.
See the Remarks section of the ICommand interface for details and examples about commands.
Public classTargetedCommandTTarget
Represents a command, which is unaware of its triggering sources and has one or more bound targets.
See the Remarks section of the ICommand interface for details and examples about commands.
Public classUndoableObjectBase
Represents an object with step-by-step undo/redo capabilities by adding ICanUndoRedo implementation to the PersistableObjectBase class. Undoing and redoing works for properties set through the IPersistableObject implementation and the ObservableObjectBase.Set method.
See the Remarks section for details.
Public classValidatingObjectBase
Represents an object with validating capabilities by adding IValidatingObject implementation to the PersistableObjectBase class.
See the Remarks section for details and examples.
Public classValidationResult
Represents a validation entry in a ValidationResultsCollection.
Public classValidationResultsCollection
Represents a collection of ValidationResult entries.
Public classVersionConverter
Provides a type converter to convert Version instances to and from their String representation.
Interfaces

  InterfaceDescription
Public interfaceICanEdit
Represents an object with nested committable and revertible editing capability.
Public interfaceICanUndo
Represents an object with undo capability.
Public interfaceICanUndoRedo
Represents an object with undo and redo capability.
Public interfaceICommand
Represents a command, which can be used to create a binding between an event of one or more sources and zero or more target objects. Can be used easily to bind events with targets with any technology.
See the Remarks section for details.
Public interfaceICommandBinding
Represents a binding for a command.
See the Remarks section for details.
Public interfaceICommandSource
Represents source information about the command.
See the Remarks section of the ICommand interface for details and examples about commands.
Public interfaceICommandSourceTEventArgs
Represents source information about the command.
See the Remarks section of the ICommand interface for details and examples about commands.
Public interfaceICommandState
Represents the states of a command for a specific command binding. When a state value is set (eg. Enabled) it can be applied for all of the command sources. By default, no application occurs but this can be overridden if an ICommandStateUpdater is added to the binding by the ICommandBinding.AddStateUpdater method. For example, if the command sources are UI elements (eg. a button and a menu item), then the Enabled or any arbitrary state (eg. text, image, shortcut, etc.) can be applied to the sources as properties.
See the Remarks section for details.
Public interfaceICommandStateUpdater
Represents an updater for the ICommandState entries that apply the state values on the command source instances. For example, if the command source is a UI element such as a button or menu item, then the Enabled property or any arbitrary state (eg. text, image, shortcut, etc.) can be applied to the sources.
See the Remarks section for details.
Public interfaceIPersistableObject
Represents an object that can store its own properties and is able to notify its consumer about property changes.
Public interfaceIValidatingObject
Represents an object that can be validated.
Enumerations

  EnumerationDescription
Public enumerationEditableObjectBehavior
Represents the behavior of an ICanEdit implementation when it is treated as an IEditableObject.
Public enumerationValidationSeverity
Represents the severity level of a ValidationResult.