Namespace: Consultingwerk.OERA
Class 
ServiceInterface Copy to Clipboard
Parent classes:
Inherits: Progress.Lang.Object

File:ServiceInterface
Purpose:The OERA ServiceInterface which is the suggested
method of accessing business logic
Author(s):Mike Fechner / Consultingwerk Ltd.
Created:Thu Mar 04 07:37:32 CET 2010



Top Method Summary
Options Name Purpose
+ Activate () Executed when we begin handling a request
+ Deactivate () Executed when we finish handling a request
+ EvaluateRequestAuthorizationProvider () (Re-)Evaluates the current IRequestAuthorizationProvider service
+ FetchData (character, IFetchDataRequest, dataset-handle) Reads data from a Business Entity
+ FetchDataset (character, dataset-handle) Returns an Empty Dataset (schema)
+ Consultingwerk.OERA.IBusinessEntity GetBusinessEntity (character) Returns the reference to the Business Entity instance
+ InvokeMethod (character, character, dataset-handle, longchar) Invokes a custom method of the BusinessEntity.
+ InvokeMethod (character, character, dataset-handle, Object) Invokes a custom method of the BusinessEntity.
+ InvokeTask (character, character, dataset-handle, dataset-handle, dataset-handle, dataset-handle, dataset-handle, Object) Invokes a method in a Task class.
+ InvokeTask (character, character, dataset-handle, dataset-handle, dataset-handle, dataset-handle, Object) Invokes a method in a Task class.
+ InvokeTask (character, character, dataset-handle, dataset-handle, dataset-handle, Object) Invokes a method in a Task class.
+ InvokeTask (character, character, dataset-handle, dataset-handle, Object) Invokes a method in a Task class.
+ InvokeTask (character, character, dataset-handle, Object) Invokes a method in a Task class.
+ InvokeTask (character, character, integer, dataset-handle, dataset-handle, dataset-handle, dataset-handle, dataset-handle, longchar) Invokes a method in a Task class.
+ InvokeTask (character, character, integer, dataset-handle, dataset-handle, dataset-handle, dataset-handle, dataset-handle, Object) Invokes a method in a Task class.
+ InvokeTask (character, character, Object) Invokes a method in a Task class.
# OnActivated (EventArgs) Raises the Activated event
# OnDeactivated (EventArgs) Raises the Deactivated event
+ SaveChanges (character, dataset-handle) Saves modified (Create, Update, Delete) data to a Business Entity
+ SaveChanges (character, dataset-handle, Object) Saves modified (Create, Update, Delete) data to a Business Entity
+ StopBusinessEntity (character) Stops an Business Entity Instance
+ LOGICAL ValidateBusinessEntityName (character) Validates a Business Entity or Business Task Name

Top Constructor Summary
Options Name Purpose
ServiceInterface () Static constructor of the ServiceInterface class

Top Event Summary
Options Name Purpose
+ Activated (EventArgs) Raised when the Service Interface begins handling a request
+ Deactivated (EventArgs) Raised when the Service Interface is finished handling a request

Top Property Summary
Options Name Purpose
+ CHARACTER CUSTOM_LOG_ENTRY Gets the custom log file entry used by the ServiceInterface class
+ LOGICAL IsActive Indicates if the ServiceInterface is currently performing a request
+ Consultingwerk.OERA.Enum.ServiceInterfaceLoggingLevelEnum LoggingLevel Get's and Set's the logging level of the ServiceInterface class


Method Detail
Top

PUBLIC Activate ()

Purpose: Executed when we begin handling a request
Notes: This method is PUBLIC to allow Pacfic WebHandlers and REST Service
classes to activate the session prior to calling into the service
interface. This is important to allow the RestServerSessionActivator
(or similar activate handlers) to instantiate the Context Dataset
(from the Context Dataset Store) prior to calling into the
Service Interface

Top

PUBLIC Deactivate ()

Purpose: Executed when we finish handling a request
Notes: See notes of the Activate() method

Top

PUBLIC EvaluateRequestAuthorizationProvider ()

Purpose: (Re-)Evaluates the current IRequestAuthorizationProvider service
Notes:

Top

PUBLIC FetchData (character, IFetchDataRequest, dataset-handle)

Purpose: Reads data from a Business Entity
Notes: Request Parameters are send using the IFetchDataRequest object
Server-side code calling directly into the Service Interface is _NOT_
supposed to call this method "BY-REFERENCE" as this is the place where
the caller receives a copy of the Business Entities ProDataset

Parameters:
pcEntityName CHARACTER
The name of the Business Entity
poFetchDataRequest Consultingwerk.OERA.IFetchDataRequest
The IFetchDataRequest instance with the data for this call
phDataset DATASET-HANDLE
OUTPUT DATASET-HANDLE The dataset with the resultset - do not pass BY-REFERENCE
Top

PUBLIC FetchDataset (character, dataset-handle)

Purpose: Returns an Empty Dataset (schema)
Notes: The caller of this method is responsible to clean up the Dataset
when no longer used! The caller should always invoke this method
with the dataset output parameter BY-REFERENCE!

Parameters:
pcEntityName CHARACTER
The name of the Business Entity
phDataset DATASET-HANDLE
OUTPUT DATASET-HANDLE The empty dataset
Top

PUBLIC Consultingwerk.OERA.IBusinessEntity GetBusinessEntity (character)

Purpose: Returns the reference to the Business Entity instance
Notes: Facade to Consultingwerk.OERA.ServiceManager:GetBusinessEntity
(pcEntityName)

Parameters:
pcEntityName CHARACTER
The name of the Business Entity to return
Returns Consultingwerk.OERA.IBusinessEntity
The reference to the Business Entity
Top

PUBLIC InvokeMethod (character, character, dataset-handle, longchar)

Purpose: Invokes a custom method of the BusinessEntity.
Notes:

Parameters:
pcEntityName CHARACTER
The name of the Business Entity class
pcMethodName CHARACTER
The name of the method of the task to execute
phDataset DATASET-HANDLE
INPUT-OUTPUT DATASET-HANDLE The dataset-handle parameter to the task method
plcParameter LONGCHAR
The LONGCHAR representation of the serialized parameter object
Top

PUBLIC InvokeMethod (character, character, dataset-handle, Object)

Purpose: Invokes a custom method of the BusinessEntity.
Notes:

Parameters:
pcEntityName CHARACTER
The name of the Business Entity class
pcMethodName CHARACTER
The name of the method of the task to execute
phDataset DATASET-HANDLE
INPUT-OUTPUT DATASET-HANDLE The dataset-handle parameter to the task method
poParameter Progress.Lang.Object
The parameter object
Top

PUBLIC InvokeTask (character, character, dataset-handle, dataset-handle, dataset-handle, dataset-handle, dataset-handle, Object)

Purpose: Invokes a method in a Task class.
Notes: When no MethodName is passed then "Invoke" will be executed as the
default task method

Parameters:
pcTaskName CHARACTER
The name of the task class
pcMethodName CHARACTER
The name of the business entity method to invoke
phDataset1 DATASET-HANDLE
INPUT-OUTPUT DATASET-HANDLE The handle of the first dataset to be passed to the task method
phDataset2 DATASET-HANDLE
INPUT-OUTPUT DATASET-HANDLE The handle of the second dataset to be passed to the task method
phDataset3 DATASET-HANDLE
INPUT-OUTPUT DATASET-HANDLE The handle of the third dataset to be passed to the task method
phDataset4 DATASET-HANDLE
INPUT-OUTPUT DATASET-HANDLE The handle of the fourth dataset to be passed to the task method
phDataset5 DATASET-HANDLE
INPUT-OUTPUT DATASET-HANDLE The handle of the fifth dataset to be passed to the task method
poParameter Progress.Lang.Object
The parameter object to the method
Top

PUBLIC InvokeTask (character, character, dataset-handle, dataset-handle, dataset-handle, dataset-handle, Object)

Purpose: Invokes a method in a Task class.
Notes: When no MethodName is passed then "Invoke" will be executed as the
default task method

Parameters:
pcTaskName CHARACTER
The name of the task class
pcMethodName CHARACTER
The name of the business entity method to invoke
phDataset1 DATASET-HANDLE
INPUT-OUTPUT DATASET-HANDLE The handle of the first dataset to be passed to the task method
phDataset2 DATASET-HANDLE
INPUT-OUTPUT DATASET-HANDLE The handle of the second dataset to be passed to the task method
phDataset3 DATASET-HANDLE
INPUT-OUTPUT DATASET-HANDLE The handle of the third dataset to be passed to the task method
phDataset4 DATASET-HANDLE
INPUT-OUTPUT DATASET-HANDLE The handle of the fourth dataset to be passed to the task method
poParameter Progress.Lang.Object
The parameter object to the method
Top

PUBLIC InvokeTask (character, character, dataset-handle, dataset-handle, dataset-handle, Object)

Purpose: Invokes a method in a Task class.
Notes: When no MethodName is passed then "Invoke" will be executed as the
default task method

Parameters:
pcTaskName CHARACTER
The name of the task class
pcMethodName CHARACTER
The name of the business entity method to invoke
phDataset1 DATASET-HANDLE
INPUT-OUTPUT DATASET-HANDLE The handle of the first dataset to be passed to the task method
phDataset2 DATASET-HANDLE
INPUT-OUTPUT DATASET-HANDLE The handle of the second dataset to be passed to the task method
phDataset3 DATASET-HANDLE
INPUT-OUTPUT DATASET-HANDLE The handle of the third dataset to be passed to the task method
poParameter Progress.Lang.Object
The parameter object to the method
Top

PUBLIC InvokeTask (character, character, dataset-handle, dataset-handle, Object)

Purpose: Invokes a method in a Task class.
Notes: When no MethodName is passed then "Invoke" will be executed as the
default task method

Parameters:
pcTaskName CHARACTER
The name of the task class
pcMethodName CHARACTER
The name of the business entity method to invoke
phDataset1 DATASET-HANDLE
INPUT-OUTPUT DATASET-HANDLE The handle of the first dataset to be passed to the task method
phDataset2 DATASET-HANDLE
INPUT-OUTPUT DATASET-HANDLE The handle of the second dataset to be passed to the task method
poParameter Progress.Lang.Object
The parameter object to the method
Top

PUBLIC InvokeTask (character, character, dataset-handle, Object)

Purpose: Invokes a method in a Task class.
Notes: When no MethodName is passed then "Invoke" will be executed as the
default task method

Parameters:
pcTaskName CHARACTER
The name of the task class
pcMethodName CHARACTER
The name of the business entity method to invoke
phDataset1 DATASET-HANDLE
INPUT-OUTPUT DATASET-HANDLE The handle of the first dataset to be passed to the task method
poParameter Progress.Lang.Object
The parameter object to the method
Top

PUBLIC InvokeTask (character, character, integer, dataset-handle, dataset-handle, dataset-handle, dataset-handle, dataset-handle, longchar)

Purpose: Invokes a method in a Task class.
Notes: When no MethodName is passed then "Invoke" will be executed as the
default task method

Parameters:
pcTaskName CHARACTER
The name of the task class
pcMethodName CHARACTER
The name of the method of the task to execute
piNumDatasets INTEGER
The number of datasets that were passed in from the consumer
phDataset1 DATASET-HANDLE
INPUT-OUTPUT DATASET-HANDLE The first dataset-handle parameter to the task method
phDataset2 DATASET-HANDLE
INPUT-OUTPUT DATASET-HANDLE The second dataset-handle parameter to the task method
phDataset3 DATASET-HANDLE
INPUT-OUTPUT DATASET-HANDLE The third dataset-handle parameter to the task method
phDataset4 DATASET-HANDLE
INPUT-OUTPUT DATASET-HANDLE The fourth dataset-handle parameter to the task method
phDataset5 DATASET-HANDLE
INPUT-OUTPUT DATASET-HANDLE The fifth dataset-handle parameter to the task method
plcParameter LONGCHAR
The LONGCHAR representation of the serialized parameter object
Top

PUBLIC InvokeTask (character, character, integer, dataset-handle, dataset-handle, dataset-handle, dataset-handle, dataset-handle, Object)

Purpose: Invokes a method in a Task class.
Notes: When no MethodName is passed then "Invoke" will be executed as the
default task method
Purpose: Invokes a method in a Task class.
Notes: When no MethodName is passed then "Invoke" will be executed as the
default task method

Parameters:
pcTaskName CHARACTER
The name of the task class
pcMethodName CHARACTER
The name of the method of the task to execute
piNumDatasets INTEGER
The number of datasets that were passed in from the consumer
phDataset1 DATASET-HANDLE
INPUT-OUTPUT DATASET-HANDLE The first dataset-handle parameter to the task method
phDataset2 DATASET-HANDLE
INPUT-OUTPUT DATASET-HANDLE The second dataset-handle parameter to the task method
phDataset3 DATASET-HANDLE
INPUT-OUTPUT DATASET-HANDLE The third dataset-handle parameter to the task method
phDataset4 DATASET-HANDLE
INPUT-OUTPUT DATASET-HANDLE The fourth dataset-handle parameter to the task method
phDataset5 DATASET-HANDLE
INPUT-OUTPUT DATASET-HANDLE The fifth dataset-handle parameter to the task method
poParameter Progress.Lang.Object
The parameter object
Top

PUBLIC InvokeTask (character, character, Object)

Purpose: Invokes a method in a Task class.
Notes: When no MethodName is passed then "Invoke" will be executed as the
default task method

Parameters:
pcTaskName CHARACTER
The name of the task class
pcMethodName CHARACTER
The name of the business entity method to invoke
poParameter Progress.Lang.Object
The parameter object to the method
Top

PROTECTED OnActivated (EventArgs)

Purpose: Raises the Activated event
Notes:

Parameters:
e Consultingwerk.EventArgs
The Consultingwerk.EventArgs with the data for this event
Top

PROTECTED OnDeactivated (EventArgs)

Purpose: Raises the Deactivated event
Notes:

Parameters:
e Consultingwerk.EventArgs
The Consultingwerk.EventArgs with the data for this event
Top

PUBLIC SaveChanges (character, dataset-handle)

Purpose: Saves modified (Create, Update, Delete) data to a Business Entity
Notes: It's recommended but not required to just pass a changes dataset

Parameters:
pcEntityName CHARACTER
The name of the Business Entity to save the modified data with
phDataset DATASET-HANDLE
INPUT-OUTPUT DATASET-HANDLE The handle of the dataset with the modified values
Top

PUBLIC SaveChanges (character, dataset-handle, Object)

Purpose: Saves modified (Create, Update, Delete) data to a Business Entity
Notes: It's recommended but not required to just pass a changes dataset

Parameters:
pcEntityName CHARACTER
The name of the Business Entity to save the modified data with
phDataset DATASET-HANDLE
INPUT-OUTPUT DATASET-HANDLE The handle of the dataset with the modified values
poParameter Progress.Lang.Object
The reference to the optional parameter object instance
Top

PUBLIC StopBusinessEntity (character)

Purpose: Stops an Business Entity Instance
Notes: Facade to Consultingwerk.OERA.ServiceManager:StopBusinessEntity
(pcEntityName)

Parameters:
pcEntityName CHARACTER
The name of the Business Entity to stop
Top

PUBLIC LOGICAL ValidateBusinessEntityName (character)

Purpose: Validates a Business Entity or Business Task Name
Notes:

Parameters:
pcEntityName CHARACTER
The name of the Business Entity to validate
Returns LOGICAL
Logical value indicating if the Business Entity name is valid


Constructor Detail
Top

STATIC ServiceInterface ()

Purpose: Static constructor of the ServiceInterface class
Notes:



Event Detail
Top

PUBLIC Activated (EventArgs)

Purpose: Raised when the Service Interface begins handling a request
Notes:

Parameters:
e Consultingwerk.EventArgs
The Consultingwerk.EventArgs with the data for this event
Top

PUBLIC Deactivated (EventArgs)

Purpose: Raised when the Service Interface is finished handling a request
Notes:

Parameters:
e Consultingwerk.EventArgs
The Consultingwerk.EventArgs with the data for this event


Property Detail
Top

PUBLIC CHARACTER CUSTOM_LOG_ENTRY

Purpose: Gets the custom log file entry used by the ServiceInterface class
Notes:

Returns CHARACTER
Top

PUBLIC LOGICAL IsActive

Purpose: Indicates if the ServiceInterface is currently performing a request
Notes:

Returns LOGICAL
Top

PUBLIC Consultingwerk.OERA.Enum.ServiceInterfaceLoggingLevelEnum LoggingLevel

Purpose: Get's and Set's the logging level of the ServiceInterface class
Notes: Currently only None and Request are supported. Possible
future values are: RequestDetail, Response, ResponseDetail

Returns Consultingwerk.OERA.Enum.ServiceInterfaceLoggingLevelEnum


©2006-2016 Consultingwerk Ltd.         info@consultingwerk.de         http://www.consultingwerk.de       26.08.2016 08:30:28