Class BlinkIdentity

java.lang.Object
com.tccc.kos.commons.core.service.blink.BlinkIdentity
Direct Known Subclasses:
BinaryMsgIdentity

public class BlinkIdentity extends Object
Base class for blink identity information. When an blink client connects to java it first sends a null terminated json encoded identity payload that describes the session. This is used to determine which session to create for the connection as well as how to configure the session, including protocol details and such. Each session can extend this class to define an identity object specific to that session so it can be decoded and passed to the session, allowing it to configure itself according to the needs of the client.

For example BinaryMsgSession uses a binary encoded protocol. The client, which is typically C code running on native hardware, may be running big endian or little endian. The identity payload can describe the data encoding so that java automatically encodes/decodes the data the correct way.

Since:
1.0
Version:
2022-08-30
  • Constructor Details

    • BlinkIdentity

      public BlinkIdentity()
  • Method Details

    • validate

      public void validate()
    • getNodeId

      public NodeId getNodeId()
      Return the nodeId of the identity.
    • getName

      public String getName()
    • isPrimary

      public boolean isPrimary()
    • getNodeType

      public String getNodeType()
    • getNodeName

      public String getNodeName()
    • getProtocol

      public String getProtocol()
    • getRevision

      public int getRevision()
    • setName

      public void setName(String name)
    • setPrimary

      public void setPrimary(boolean primary)
    • setNodeType

      public void setNodeType(String nodeType)
    • setNodeName

      public void setNodeName(String nodeName)
    • setProtocol

      public void setProtocol(String protocol)
    • setRevision

      public void setRevision(int revision)
    • toString

      public String toString()
      Overrides:
      toString in class Object