com.apama.sor.oms
Event OrderState


The OrderState event helper provides a container for details relating to supported order states.

These are as defined in the OrderManager service block, i.e. WAITING, WORKING, COMPLETE, REJECT, PENDING_CHANGE, PENDING_CANCEL, CANCELLED, SUSPENDED and UNKNOWN.
Since:
CMF 2.1.0

Constant summary
 constant integerCANCELLED := 7
 constant integerCOMPLETE := 3
 constant integerPENDING_CANCEL := 6
 constant integerPENDING_CHANGE := 5
 constant integerREJECT := 4
 constant integerSUSPENDED := 8
 constant integerUNKNOWN := 9
 constant integerWAITING := 1
 constant integerWORKING := 2
 
Member summary
 wildcard integerstate
 
Action summary
 voidcalculate(com.apama.oms.OrderUpdate update)

Helper action to calculate the state of the order based on the previous state and latest update. The action does not return a value. but rather sets the self.state parameter to the new state value. Access to this is via the accessor actions of the event.
 booleanequals(com.apama.sor.oms.OrderState check)
 integergetInteger()
 stringgetString()
 booleanisCancelled()
 booleanisComplete()
 booleanisFinal()
 booleanisPendingCancel()
 booleanisPendingChange()
 booleanisReject()
 booleanisSuspended()
 booleanisUnknown()
 booleanisWaiting()
 booleanisWorking()
 dictionary<integer, string>LOOKUP()
 voidset(integer state)
 voidsetCancelled()
 voidsetComplete()
 voidsetPendingCancel()
 voidsetPendingChange()
 voidsetReject()
 voidsetSuspended()
 voidsetUnknown()
 voidsetWaiting()
 voidsetWorking()
 
Constant detail

CANCELLED

            constant integer CANCELLED := 7
        

COMPLETE

            constant integer COMPLETE := 3
        

PENDING_CANCEL

            constant integer PENDING_CANCEL := 6
        

PENDING_CHANGE

            constant integer PENDING_CHANGE := 5
        

REJECT

            constant integer REJECT := 4
        

SUSPENDED

            constant integer SUSPENDED := 8
        

UNKNOWN

            constant integer UNKNOWN := 9
        

WAITING

            constant integer WAITING := 1
        

WORKING

            constant integer WORKING := 2
        

Member detail

state

            wildcard integer state
        

Action detail

calculate

            void calculate(com.apama.oms.OrderUpdate update)
        
Helper action to calculate the state of the order based on the previous state and latest update. The action does not return a value. but rather sets the self.state parameter to the new state value. Access to this is via the accessor actions of the event.
Parameters:
update - The most com.apama.oms.OrderUpdate event to be translated into a state based on the current state (as given by self.state)

equals

            boolean equals(com.apama.sor.oms.OrderState check)
        
Parameters:
check

getInteger

            integer getInteger()
        

getString

            string getString()
        

isCancelled

            boolean isCancelled()
        

isComplete

            boolean isComplete()
        

isFinal

            boolean isFinal()
        

isPendingCancel

            boolean isPendingCancel()
        

isPendingChange

            boolean isPendingChange()
        

isReject

            boolean isReject()
        

isSuspended

            boolean isSuspended()
        

isUnknown

            boolean isUnknown()
        

isWaiting

            boolean isWaiting()
        

isWorking

            boolean isWorking()
        

LOOKUP

            dictionary<integer, string> LOOKUP()
        

set

            void set(integer state)
        
Parameters:
state

setCancelled

            void setCancelled()
        

setComplete

            void setComplete()
        

setPendingCancel

            void setPendingCancel()
        

setPendingChange

            void setPendingChange()
        

setReject

            void setReject()
        

setSuspended

            void setSuspended()
        

setUnknown

            void setUnknown()
        

setWaiting

            void setWaiting()
        

setWorking

            void setWorking()