Class Command

java.lang.Object
com.epam.admintool.commands.Command
Direct Known Subclasses:
ChangeSeqNum, CreateAcceptor, CreateInitiator, DefaultCommand, Delete, DeleteAll, GeneralSessionsStat, GetFIXProtocolsList, Heartbeat, Help, ProceedStat, ReceivedStat, ResetSeqNum, SendMessage, SentStat, SessionParams, SessionsList, SessionsSnapshot, SessionStat, SessionStatus, StopSession, TestRequest, ToBackup, ToPrimary

public abstract class Command extends Object
Common interface for all command of Administrative tool.
  • Field Details

    • request

      protected com.epam.fixicc.message.Request request
    • response

      protected com.epam.fixicc.message.ResponseData response
    • xmlContent

      protected String xmlContent
    • adminFixSession

      protected FIXSession adminFixSession
    • configuredSessionRegister

      protected com.epam.fixengine.manager.ConfiguredSessionRegister configuredSessionRegister
  • Constructor Details

    • Command

      protected Command()
  • Method Details

    • getRequest

      public com.epam.fixicc.message.Request getRequest()
      Getter for request.
    • setRequest

      public void setRequest(com.epam.fixicc.message.Request request)
      Setter for request.
      Parameters:
      request - the request
    • getRequestID

      public Long getRequestID()
      Gets request id from request.

      if request not set returns null

    • setAdminFixSession

      public void setAdminFixSession(FIXSession adminFixSession)
      Setter for admin session.
      Parameters:
      adminFixSession - the admin session
    • getAdminFixSession

      public FIXSession getAdminFixSession()
      getter for admin fix session.
    • setConfiguredSessionRegister

      public void setConfiguredSessionRegister(com.epam.fixengine.manager.ConfiguredSessionRegister configuredSessionRegister)
    • getConfiguredSessionRegister

      public com.epam.fixengine.manager.ConfiguredSessionRegister getConfiguredSessionRegister()
    • execute

      public abstract void execute()
      Execute command.
    • sendResponse

      protected void sendResponse(com.epam.fixicc.message.Response response)
      Send response.
      Parameters:
      response -
    • sendResponseSuccess

      public void sendResponseSuccess(com.epam.fixicc.message.Response response)
      Send response.
      Parameters:
      response -
    • sendResponse

      protected void sendResponse(String problem, String errorCode)
      Send response.
      Parameters:
      problem -
      errorCode -
    • sendReject

      protected void sendReject(String problem)
      Send reject.
      Parameters:
      problem -
    • sendError

      public void sendError(String problem)
      Send error.
      Parameters:
      problem -
    • sendInvalidArgument

      protected void sendInvalidArgument(String problem)
      Send invalid argument.
      Parameters:
      problem -
    • sendUnknownSession

      @Deprecated protected void sendUnknownSession(String sender, String target)
      Deprecated.
      Send error with unknown session.
    • sendUnknownSession

      protected void sendUnknownSession(String id)
      Send error with unknown session.
    • setXmlContent

      public void setXmlContent(String xmlContent)
      Setter for xmlContent
    • getFIXSession

      protected ExtendedFIXSession getFIXSession(String sender, String target, String qualifier)
      Gets the fix session.
      Parameters:
      sender - - sender
      target - - target
      qualifier - - qualifier
    • getFIXSession

      protected ExtendedFIXSession getFIXSession(SessionID sessionID)
      Gets the fix session.
      Parameters:
      sessionID - - sessionID
    • getConfiguredSession

      protected SessionParameters getConfiguredSession(String senderCompID, String targetCompID, String qualifier)
      Gets the configured fix session.
      Parameters:
      senderCompID - - sender
      targetCompID - - target
      qualifier - - qualifier
    • getConfiguredSession

      protected SessionParameters getConfiguredSession(SessionID sessionID)
      Gets the fix session.
      Parameters:
      sessionID - - sessionID
    • areKeySessionParamsEqual

      protected boolean areKeySessionParamsEqual(SessionParameters parameters, SessionID sessionID)
    • getFIXSessions

      protected List<ExtendedFIXSession> getFIXSessions()
      Gets fix session list.
    • getConfiguredSessionParameters

      protected List<SessionParameters> getConfiguredSessionParameters()
      Gets the configured fix session list.