110 lines
2.5 KiB
Plaintext
110 lines
2.5 KiB
Plaintext
|
@startuml
|
||
|
namespace frame {
|
||
|
class AcceptedFrame << (S,Aquamarine) >> {
|
||
|
+ Type() Type
|
||
|
+ Encode() []byte
|
||
|
|
||
|
}
|
||
|
class BackFlowFrame << (S,Aquamarine) >> {
|
||
|
+ Tag byte
|
||
|
+ Carriage []byte
|
||
|
|
||
|
+ Type() Type
|
||
|
+ SetCarriage(buf []byte) *BackFlowFrame
|
||
|
+ Encode() []byte
|
||
|
+ GetDataTag() byte
|
||
|
+ GetCarriage() []byte
|
||
|
|
||
|
}
|
||
|
class DataFrame << (S,Aquamarine) >> {
|
||
|
- metaFrame *MetaFrame
|
||
|
- payloadFrame *PayloadFrame
|
||
|
|
||
|
+ Type() Type
|
||
|
+ Tag() byte
|
||
|
+ SetCarriage(tag byte, carriage []byte)
|
||
|
+ GetCarriage() []byte
|
||
|
+ TransactionId() string
|
||
|
+ SetTransactionId(transactionID string)
|
||
|
+ GetMetaFrame() *MetaFrame
|
||
|
+ GetDataTag() byte
|
||
|
+ SetSourceId(sourceID string)
|
||
|
+ SourceId() string
|
||
|
+ Encode() []byte
|
||
|
|
||
|
}
|
||
|
interface Frame {
|
||
|
+ Type() Type
|
||
|
+ Encode() []byte
|
||
|
|
||
|
}
|
||
|
class GoawayFrame << (S,Aquamarine) >> {
|
||
|
- message string
|
||
|
|
||
|
+ Type() Type
|
||
|
+ Encode() []byte
|
||
|
+ Message() string
|
||
|
|
||
|
}
|
||
|
class HandshakeFrame << (S,Aquamarine) >> {
|
||
|
- authName string
|
||
|
- authPayload string
|
||
|
|
||
|
+ Name string
|
||
|
+ ClientId string
|
||
|
+ ClientType byte
|
||
|
+ ObserveDataTags []byte
|
||
|
|
||
|
+ Type() Type
|
||
|
+ Encode() []byte
|
||
|
+ AuthPayload() string
|
||
|
+ AuthName() string
|
||
|
|
||
|
}
|
||
|
class MetaFrame << (S,Aquamarine) >> {
|
||
|
- tid string
|
||
|
- metadata []byte
|
||
|
- sourceId string
|
||
|
|
||
|
+ SetTransactionId(transactionId string)
|
||
|
+ TransactionId() string
|
||
|
+ SetMetadata(metadata []byte)
|
||
|
+ Metadata() []byte
|
||
|
+ SetSourceId(sourceId string)
|
||
|
+ SourceId() string
|
||
|
+ Encode() []byte
|
||
|
|
||
|
}
|
||
|
class PayloadFrame << (S,Aquamarine) >> {
|
||
|
+ Tag byte
|
||
|
+ Carriage []byte
|
||
|
|
||
|
+ SetCarriage(buf []byte) *PayloadFrame
|
||
|
+ Encode() []byte
|
||
|
|
||
|
}
|
||
|
class RejectedFrame << (S,Aquamarine) >> {
|
||
|
- message string
|
||
|
|
||
|
+ Type() Type
|
||
|
+ Encode() []byte
|
||
|
+ Message() string
|
||
|
|
||
|
}
|
||
|
class Type << (S,Aquamarine) >> {
|
||
|
+ String() string
|
||
|
|
||
|
}
|
||
|
class frame.Type << (T, #FF7700) >> {
|
||
|
}
|
||
|
}
|
||
|
|
||
|
"frame.Frame" <|-- "frame.AcceptedFrame"
|
||
|
"frame.Frame" <|-- "frame.BackFlowFrame"
|
||
|
"frame.Frame" <|-- "frame.DataFrame"
|
||
|
"frame.Frame" <|-- "frame.GoawayFrame"
|
||
|
"frame.Frame" <|-- "frame.HandshakeFrame"
|
||
|
"frame.Frame" <|-- "frame.RejectedFrame"
|
||
|
|
||
|
"__builtin__.uint8" #.. "frame.Type"
|
||
|
@enduml
|