|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Provides an interface for a TLV chain whose contents can be modified.
Method Summary | |
void |
addAll(TlvChain other)
Adds all TLV's in the given chain to the end of this chain (preserving order). |
void |
addTlv(Tlv tlv)
Adds the given TLV to this chain. |
void |
removeTlv(Tlv tlv)
Removes the given TLV from the chain, if it is present. |
void |
removeTlvs(int type)
Removes all TLV's in this chain of the given TLV type. |
void |
removeTlvs(int[] types)
Removes all TLV's in this chain having any of the given types. |
void |
replaceAll(TlvChain other)
Deletes all TLV's currently in this chain having the same type as any of the TLV's in the other chain, and replaces them with their counterparts in the given chain. |
void |
replaceTlv(Tlv tlv)
Removes all TLV's of the given type from the chain, and inserts the given TLV at the index of the first TLV removed, or at the end of the chain if no TLV's of the same type were found. |
Methods inherited from interface TlvChain |
getFirstTlv, getLastTlv, getString, getString, getTlvCount, getTlvs, getTlvs, getTotalSize, getUInt, getUShort, hasTlv, iterator |
Methods inherited from interface net.kano.joscar.Writable |
getWritableLength, write |
Method Detail |
public void addTlv(Tlv tlv)
tlv
- the TLV to addpublic void replaceTlv(Tlv tlv)
tlv
- the TLV to replace its "siblings" of the same TLV typepublic void removeTlv(Tlv tlv)
tlv
- the TLV to removepublic void removeTlvs(int type)
type
- the type of TLV of which to remove all instancespublic void removeTlvs(int[] types)
types
- the TLV types of which to remove all instancespublic void addAll(TlvChain other)
other
- the chain whose TLV's will be appended to this chainpublic void replaceAll(TlvChain other)
other
- the TLV whose TLV's will replace and/or add to TLV's in this
chain
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |