Skip to content

AppManagerBase

SAIF.Application.AppManagerBase is the library's central abstract base class for classic application managers. It defines lifecycle hooks, message handling, data-layer access, and role-state accessors for consuming implementations.

Purpose

  • Provide a common contract for application-manager initialization, validation, retrieval, writing, and transaction hooks.
  • Expose a shared security-role model and message accumulation behavior for consuming managers.

Context

  • Namespace: SAIF.Application
  • Assembly/package: SAIF.BOF.Application

Public members

Member Signature Purpose
AppSecurityRole Public Enum AppSecurityRole Define the ViewOnly, Update, and NoAccess role values returned by SecurityRole.
DefaultNewLineCharacter Public Const DefaultNewLineCharacter As String = "<BR>" Define the default separator used between accumulated message lines.
MSG_SAVE Public Const MSG_SAVE As String = "Changes saved." Provide the standard success message for completed save operations.
MSG_NO_SAVE Public Const MSG_NO_SAVE As String = "No Changes to Save." Provide the standard message used when no pending changes are written.
MSG_SAVE_FAILED Public Const MSG_SAVE_FAILED As String = "Save failed." Provide the standard failure message for unsuccessful save processing.
IsAccessible Public ReadOnly Property IsAccessible() As Boolean Return True when SecurityRole is not NoAccess.
IsRestricted Public ReadOnly Property IsRestricted() As Boolean Return True when SecurityRole is NoAccess.
IsUpdateable Public ReadOnly Property IsUpdateable() As Boolean Return True when SecurityRole is Update.
IsViewOnly Public ReadOnly Property IsViewOnly() As Boolean Return True when SecurityRole is ViewOnly.
Message Public Property Message() As String Expose the accumulated manager message string while restricting writes to the type and its friends.
NewLineCharacter Public Property NewLineCharacter() As String Get or set the separator appended between unique message lines.
SecurityRole Public ReadOnly Property SecurityRole() As AppSecurityRole Return the current effective application security role.
ValidContext Public ReadOnly Property ValidContext() As Boolean Return the current context validation result supplied by OnValidContext().
Retrieve Public MustOverride Function Retrieve() As Boolean Require derived managers to implement the public retrieval workflow.
Write Public MustOverride Function Write() As Boolean Require derived managers to implement the public write workflow.

Inherited public members

From clsBusinessBase (Legacy.BusinessObjectFramework)

Members in this section are inherited from clsBusinessBase. They are available on this type through inheritance.

Member Signature Purpose Origin
MyGuid Public ReadOnly Property MyGuid() As String Return the unique GUID assigned to the business object instance. Legacy.BusinessObjectFramework — clsBusinessBase
IsNew Public ReadOnly Property IsNew() As Boolean Report whether the object represents unsaved or deleted-backed data. Legacy.BusinessObjectFramework — clsBusinessBase
IsDeleted Public ReadOnly Property IsDeleted() As Boolean Report whether the object is marked for deletion. Legacy.BusinessObjectFramework — clsBusinessBase
IsDirty Public Overridable ReadOnly Property IsDirty() As Boolean Report whether object state has changed since load or save. Legacy.BusinessObjectFramework — clsBusinessBase
SetValueOnChange Public Function SetValueOnChange(Of T)(ByRef inFieldValue As T, ByVal inSetValue As T, Optional ByVal inMarkDirty As Boolean = True) As Boolean Compare and assign a field value, optionally marking the object dirty when the value changes. Legacy.BusinessObjectFramework — clsBusinessBase
IsSavable Public Overridable ReadOnly Property IsSavable() As Boolean Return True only when the object is both dirty and valid. Legacy.BusinessObjectFramework — clsBusinessBase
PreviousLinkItem Public ReadOnly Property PreviousLinkItem() As ILinkItem Implements ILinkItem.PreviousLinkItem Return the previous item in a linked-list chain. Legacy.BusinessObjectFramework — clsBusinessBase
NextLinkItem Public ReadOnly Property NextLinkItem() As ILinkItem Implements ILinkItem.NextLinkItem Return the next item in a linked-list chain. Legacy.BusinessObjectFramework — clsBusinessBase
SetPreviousLink Public Sub SetPreviousLink(ByRef inLinkItem As ILinkItem) Implements ILinkItem.SetPreviousLink Assign the previous linked-list item. Legacy.BusinessObjectFramework — clsBusinessBase
SetNextLink Public Sub SetNextLink(ByRef inLinkItem As ILinkItem) Implements ILinkItem.SetNextLink Assign the next linked-list item. Legacy.BusinessObjectFramework — clsBusinessBase
InsertLinkAfter Public Sub InsertLinkAfter(ByRef inLinkItem As ILinkItem) Implements ILinkItem.InsertLinkAfter Insert another item after the current item in a linked-list chain. Legacy.BusinessObjectFramework — clsBusinessBase
InsertLinkBefore Public Sub InsertLinkBefore(ByRef inLinkItem As ILinkItem) Implements ILinkItem.InsertLinkBefore Insert another item before the current item in a linked-list chain. Legacy.BusinessObjectFramework — clsBusinessBase
RemoveLinks Public Sub RemoveLinks() Implements ILinkItem.RemoveLinks Detach the current item from its linked-list neighbors. Legacy.BusinessObjectFramework — clsBusinessBase
BeginEdit Public Sub BeginEdit() Snapshot object state for an undoable edit session. Legacy.BusinessObjectFramework — clsBusinessBase
CancelEdit Public Sub CancelEdit() Restore the most recent edit snapshot and rerun business rules. Legacy.BusinessObjectFramework — clsBusinessBase
ApplyEdit Public Sub ApplyEdit() Commit the current edit snapshot. Legacy.BusinessObjectFramework — clsBusinessBase
Delete Public Sub Delete() Mark a parent object for deletion on the next save. Legacy.BusinessObjectFramework — clsBusinessBase
Clone Public Function Clone() As Object Implements ICloneable.Clone Create a serialized copy of the object. Legacy.BusinessObjectFramework — clsBusinessBase
ValidateOnDelete Public Property ValidateOnDelete() As Boolean Control whether business rules are validated after the object is marked deleted. Legacy.BusinessObjectFramework — clsBusinessBase
Rules Public ReadOnly Property Rules() As clsRulesManager Expose the rules manager associated with the object. Legacy.BusinessObjectFramework — clsBusinessBase
IsValid Public Overridable ReadOnly Property IsValid() As Boolean Run business-rule validation and return whether the object has zero errors. Legacy.BusinessObjectFramework — clsBusinessBase
ErrorCount Public ReadOnly Property ErrorCount() As Integer Return the current number of validation errors. Legacy.BusinessObjectFramework — clsBusinessBase
ErrorMessages Public ReadOnly Property ErrorMessages() As String() Return the current validation error messages. Legacy.BusinessObjectFramework — clsBusinessBase
WarningCount Public ReadOnly Property WarningCount() As Integer Return the current number of validation warnings. Legacy.BusinessObjectFramework — clsBusinessBase
WarningMessages Public ReadOnly Property WarningMessages() As String() Return the current validation warning messages. Legacy.BusinessObjectFramework — clsBusinessBase
InformationalCount Public ReadOnly Property InformationalCount() As Integer Return the current number of informational validation messages. Legacy.BusinessObjectFramework — clsBusinessBase
InformationalMessages Public ReadOnly Property InformationalMessages() As String() Return the current informational validation messages. Legacy.BusinessObjectFramework — clsBusinessBase
Save Public Overridable Function Save() As Boolean Persist a parent object according to its new, dirty, deleted, and valid state. Legacy.BusinessObjectFramework — clsBusinessBase
SaveChild Public Overridable Function SaveChild() As Boolean Persist a child object according to its new, dirty, deleted, and valid state. Legacy.BusinessObjectFramework — clsBusinessBase
XMLElementName Public Property XMLElementName() As String Get or set the XML element name used for reporting and serialization. Legacy.BusinessObjectFramework — clsBusinessBase
GetDataset Public Sub GetDataset(ByRef inDS As DataSet) Merge bindable object properties into a dataset using the type name as the table name. Legacy.BusinessObjectFramework — clsBusinessBase
GetDataset Public Sub GetDataset(ByRef inDS As DataSet, ByVal inTableName As String) Merge bindable object properties into a dataset using the supplied table name. Legacy.BusinessObjectFramework — clsBusinessBase
GetReportXML Public Function GetReportXML(ByVal inElementName As String) As String Generate report XML using the supplied root element name. Legacy.BusinessObjectFramework — clsBusinessBase
GetReportXML Public Function GetReportXML() As String Generate report XML using XMLElementName. Legacy.BusinessObjectFramework — clsBusinessBase
ToXml Public Function ToXml() As String Serialize the object to XML using the default tag name. Legacy.BusinessObjectFramework — clsBusinessBase
ToXml Public Function ToXml(ByVal inTagName As String) As String Serialize the object to XML using the supplied tag name. Legacy.BusinessObjectFramework — clsBusinessBase

Behavioral notes

  • Role-state accessors expose the mutually exclusive state documented in BR-001.
  • Message accumulation behavior suppresses duplicates as described by BR-002.
  • Concrete consuming applications supply the actual lifecycle implementation through the override hooks.

Constraints and usage notes

  • This type is abstract and intended for inheritance rather than direct instantiation.
  • Downstream SQL work is performed through injected or registered IDataPortalInfo instances rather than direct SQL in this class.
  • Authorization checks can be delegated to UserAccess or other subclass logic before role assignment occurs.

Sources

  • Application\SAIF.Application\AppManagerBase.vb
  • Legacy\BusinessObjectFramework\clsBusinessBase.vb