public abstract class WmNotification
extends java.lang.Object
implements com.wm.pkg.art.callback.CallbackDispatcher, com.wm.pkg.art.metadata.ComplexTemplate
Modifier and Type | Field and Description |
---|---|
protected boolean |
_localPublish |
protected com.wm.lang.ns.NSName |
_notificationNodeName |
protected com.wm.lang.ns.NSName |
_pubRecNodeName |
protected com.wm.lang.ns.NSName |
_repRecNodeName |
protected com.wm.lang.ns.NSName |
_reqRecNodeName |
protected com.wm.lang.ns.NSName |
_serviceName |
protected java.lang.String |
_UUID |
NOTIFY_DELETE, NOTIFY_DELETE_CALLBACK_NAME, NOTIFY_DISABLE, NOTIFY_DISABLE_CALLBACK_NAME, NOTIFY_ENABLE, NOTIFY_ENABLE_CALLBACK_NAME, NOTIFY_INIT, NOTIFY_INIT_CALLBACK_NAME, NOTIFY_RESUME, NOTIFY_RESUME_CALLBACK_NAME, NOTIFY_SHUTDOWN, NOTIFY_SHUTDOWN_CALLBACK_NAME, NOTIFY_STARTUP, NOTIFY_STARTUP_CALLBACK_NAME, NOTIFY_SUSPEND, NOTIFY_SUSPEND_CALLBACK_NAME, NOTIFY_UPDATE, NOTIFY_UPDATE_CALLBACK_NAME, ORDERED_NAME_LIST
Constructor and Description |
---|
WmNotification() |
Modifier and Type | Method and Description |
---|---|
void |
changeNotificationData(com.wm.pkg.art.scheduler.NotificationData notificationData) |
protected void |
checkTransaction()
Called to ensure no transaction is currently associated with this Thread.
|
protected void |
commitTransaction() |
abstract void |
configureIOProperties(PipelineRecordProperties input,
PipelineRecordProperties output)
Shell method to an objects setDocumentProperties implementation
implement in the appropriate subclass.
|
protected static void |
debuglog(java.lang.String s) |
void |
deleteCallBack()
This method is called when a notification is deleted.
|
void |
disableCallBack()
This method is called when a notification is disabled using the webMethods
Administrator user interface.
|
protected void |
dispatchConnectionError(WmManagedConnection wmc,
WmConnection conn,
java.lang.Throwable exception)
Dispatches a connection error.
|
void |
enableCallBack()
This method is called when a notification is enabled using the webMethods
Administrator user interface.
|
boolean |
enabled()
Returns whether this notification is enabled.
|
protected void |
errorLog(AdapterException ae)
Error logs the exception
|
NotificationResults |
execute(NotificationEvent event)
Called to actually run the notification.
|
abstract void |
fillWmTemplateDescriptor(WmTemplateDescriptor descriptor,
java.util.Locale l)
Registers non-bean-based metadata with the Integration Server.
|
protected WmConnection |
getConnection()
Returns a connection.
|
protected com.wm.pkg.art.ns.ConnectionDataNode |
getConnectionDataNode()
Returns a connection data node, based on the name of this notification.
|
java.lang.String |
getDesignTimeLocale()
Retrieves a String representation of the client locale that was used
when this notification was created.
|
void |
initCallBack()
This method is called when a notification is initialized, regardless of
the notification's enable/disable state.
|
void |
initNotificationNodeProperties(com.wm.pkg.art.ns.NotificationNode nodeObj)
This method is called by the Notification manager when a node is created.
|
abstract java.lang.String |
inputRecordName() |
protected void |
logCallback(java.lang.String callbackName)
Logs the callback.
|
protected void |
logDebugPlus(int minorCode,
java.lang.String param1)
Logs with a plus value of 1, with the FAC_ART_LISTENER facility code.
|
protected void |
logDebugPlus(int minorCode,
java.lang.String param1,
java.lang.String param2)
Logs with a plus value of 1, with the FAC_ART_LISTENER facility code.
|
protected void |
logDebugPlus(int minorCode,
java.lang.String param1,
java.lang.String param2,
java.lang.String param3)
Logs with a plus value of 1, with the FAC_ART_LISTENER facility code.
|
protected void |
logDebugPlusNamed(int minorCode)
Logs with a plus value of 1, with the FAC_ART_LISTENER facility code, and
adding the notification node name, or the unknown value from the resource
bundle, if not found.
|
protected com.wm.pkg.art.error.DetailedException |
makeDetailedException(int minorCode)
Creates a detailed exception.
|
protected com.wm.pkg.art.error.DetailedException |
makeDetailedException(int minorCode,
java.lang.String param1)
Creates a detailed exception.
|
protected com.wm.pkg.art.error.DetailedException |
makeDetailedException(int minorCode,
java.lang.String param1,
java.lang.String param2,
java.lang.Throwable t)
Creates a detailed exception.
|
protected com.wm.pkg.art.error.DetailedException |
makeDetailedException(int minorCode,
java.lang.String param1,
java.lang.Throwable t)
Creates a detailed exception.
|
java.lang.String |
nodeName()
Returns the fully qualified node name of this notification.
|
protected java.lang.String |
nodeNameOrUnknown()
Returns the node name, or "unknown" if not set.
|
void |
notifyEvent(int et)
Called to propogate the notification lifecycle events of startup, copy,
update, delete.
|
abstract java.lang.String |
outputRecordName() |
void |
populateMetadata(ComplexMetadata md,
java.util.Locale l)
Shell method to an object's filWmTemlateDescriptor method.
|
java.lang.String |
queryPackage()
Returns the package of this notification.
|
void |
resumeCallBack()
This method is called when a notification is resumed (un-suspended).
|
com.wm.pkg.art.scheduler.NotificationData |
returnNotificationData() |
protected void |
rollbackTransaction()
Called to roll back the existing transaction.
|
void |
runNotification()
Adapter writers must implement this method in their adapter's
notification templates, if they receive polling-based notifications.
|
NotificationResults |
runNotification(NotificationEvent event)
Adapter writers should implement this method in their adapter's
notification templates, if they get listener-based notifications.
|
protected void |
sendEventToEventBus(com.wm.data.IData event)
Method to send events to the event Bus.
|
void |
setDesignTimeLocale(java.lang.String val)
Java-Bean compliant accessor method to set the design-time locale data as metadata
Data is expected in the form of a pipe-delimitted string with countryCode|languageCode|[variant]
|
void |
shutdownCallBack()
This method is called before an adapter notification shuts down.
|
void |
startupCallBack()
This method is called after the Integration Server is initialized
but before the notification executes the first time.
|
void |
suspendCallBack()
This method is called when a notification is suspended.
|
void |
updateCallBack()
This method is called when a notification is updated using the Adapter
Notification Editor.
|
protected boolean _localPublish
protected com.wm.lang.ns.NSName _notificationNodeName
protected com.wm.lang.ns.NSName _pubRecNodeName
protected com.wm.lang.ns.NSName _repRecNodeName
protected com.wm.lang.ns.NSName _reqRecNodeName
protected com.wm.lang.ns.NSName _serviceName
protected java.lang.String _UUID
public void changeNotificationData(com.wm.pkg.art.scheduler.NotificationData notificationData)
protected void checkTransaction() throws com.wm.pkg.art.error.DetailedException
com.wm.pkg.art.error.DetailedException
protected void commitTransaction() throws com.wm.pkg.art.error.DetailedException
com.wm.pkg.art.error.DetailedException
public abstract void configureIOProperties(PipelineRecordProperties input, PipelineRecordProperties output) throws javax.resource.ResourceException
configureIOProperties
in interface com.wm.pkg.art.metadata.ComplexTemplate
input
- input record for the template (null if n/a)output
- output record for the templatejavax.resource.ResourceException
protected static void debuglog(java.lang.String s)
public void deleteCallBack() throws javax.resource.ResourceException
javax.resource.ResourceException
- if a processing error has occuredpublic void disableCallBack() throws javax.resource.ResourceException
javax.resource.ResourceException
- if a processing error has occuredprotected void dispatchConnectionError(WmManagedConnection wmc, WmConnection conn, java.lang.Throwable exception)
exception
- TODOpublic void enableCallBack() throws javax.resource.ResourceException
javax.resource.ResourceException
- if a processing error has occuredpublic boolean enabled()
protected void errorLog(AdapterException ae)
public final NotificationResults execute(NotificationEvent event) throws javax.resource.ResourceException
javax.resource.ResourceException
public abstract void fillWmTemplateDescriptor(WmTemplateDescriptor descriptor, java.util.Locale l) throws javax.resource.ResourceException
descriptor
- the WmTemplateDescriptor object to be populatedl
- the Locale used for UI based metadatajavax.resource.ResourceException
- if a processing error has occuredWmTemplateDescriptor
protected WmConnection getConnection() throws com.wm.pkg.art.error.DetailedException
com.wm.pkg.art.error.DetailedException
protected com.wm.pkg.art.ns.ConnectionDataNode getConnectionDataNode() throws com.wm.pkg.art.error.DetailedException
com.wm.pkg.art.error.DetailedException
public java.lang.String getDesignTimeLocale()
AdapterUtil.parseLocaleString(java.lang.String)
,
ADKGLOBAL.DESIGN_LOCALE_PROPERTY
public void initCallBack() throws javax.resource.ResourceException
javax.resource.ResourceException
- if a processing error has occuredpublic final void initNotificationNodeProperties(com.wm.pkg.art.ns.NotificationNode nodeObj) throws com.wm.pkg.art.error.DetailedException
nodeName
- The NS name for the notification node. It may not be null.com.wm.pkg.art.error.DetailedException
- Thrown if an error occurs.public abstract java.lang.String inputRecordName()
inputRecordName
in interface com.wm.pkg.art.metadata.ComplexTemplate
protected void logCallback(java.lang.String callbackName)
protected void logDebugPlus(int minorCode, java.lang.String param1)
protected void logDebugPlus(int minorCode, java.lang.String param1, java.lang.String param2)
protected void logDebugPlus(int minorCode, java.lang.String param1, java.lang.String param2, java.lang.String param3)
protected void logDebugPlusNamed(int minorCode)
protected com.wm.pkg.art.error.DetailedException makeDetailedException(int minorCode)
protected com.wm.pkg.art.error.DetailedException makeDetailedException(int minorCode, java.lang.String param1)
protected com.wm.pkg.art.error.DetailedException makeDetailedException(int minorCode, java.lang.String param1, java.lang.String param2, java.lang.Throwable t)
protected com.wm.pkg.art.error.DetailedException makeDetailedException(int minorCode, java.lang.String param1, java.lang.Throwable t)
public java.lang.String nodeName()
protected java.lang.String nodeNameOrUnknown()
public final void notifyEvent(int et) throws com.wm.pkg.art.error.DetailedException
notifyEvent
in interface com.wm.pkg.art.callback.CallbackDispatcher
et
- The type of event that just occured. It must match one of the
constants:
NotificationEventTypes.NOTIFY_UPDATE,
NotificationEventTypes.NOTIFY_DELETE,
NotificationEventTypes.NOTIFY_INIT,
NotificationEventTypes.NOTIFY_STARTUP,
NotificationEventTypes.NOTIFY_SHUTDOWN,
NotificationEventTypes.NOTIFY_ENABLE,
NotificationEventTypes.NOTIFY_DISABLEcom.wm.pkg.art.error.DetailedException
public abstract java.lang.String outputRecordName()
outputRecordName
in interface com.wm.pkg.art.metadata.ComplexTemplate
public void populateMetadata(ComplexMetadata md, java.util.Locale l) throws javax.resource.ResourceException
populateMetadata
in interface com.wm.pkg.art.metadata.ComplexTemplate
md
- l
- javax.resource.ResourceException
public java.lang.String queryPackage()
public void resumeCallBack() throws javax.resource.ResourceException
javax.resource.ResourceException
- if a processing error has occuredpublic com.wm.pkg.art.scheduler.NotificationData returnNotificationData()
protected void rollbackTransaction() throws com.wm.pkg.art.error.DetailedException
com.wm.pkg.art.error.DetailedException
public void runNotification() throws javax.resource.ResourceException
javax.resource.ResourceException
- if a processing error has occuredpublic NotificationResults runNotification(NotificationEvent event) throws javax.resource.ResourceException
javax.resource.ResourceException
- if a processing error has occuredprotected void sendEventToEventBus(com.wm.data.IData event)
event
- public void setDesignTimeLocale(java.lang.String val)
public void shutdownCallBack() throws javax.resource.ResourceException
javax.resource.ResourceException
- if a processing error has occuredpublic void startupCallBack() throws javax.resource.ResourceException
javax.resource.ResourceException
- if a processing error has occuredpublic void suspendCallBack() throws javax.resource.ResourceException
javax.resource.ResourceException
- if a processing error has occuredpublic void updateCallBack() throws javax.resource.ResourceException
javax.resource.ResourceException
- if a processing error has occured
Copyright © 2003 - 2021 Software AG, Darmstadt, Germany and/or Software AG USA Inc., Reston, VA, USA, and/or its subsidiaries and/or its affiliates and/or their licensors.