Package alexiil.mc.lib.net
Class ParentNetIdDuel<Parent,T>
java.lang.Object
alexiil.mc.lib.net.TreeNetIdBase
alexiil.mc.lib.net.ParentNetIdBase
alexiil.mc.lib.net.ParentNetIdSingle<T>
alexiil.mc.lib.net.ParentNetIdDuel<Parent,T>
- Direct Known Subclasses:
ParentDynamicNetId,ParentNetIdCast,ParentNetIdDuelDirect,ParentNetIdExtractor
-
Field Summary
FieldsFields inherited from class alexiil.mc.lib.net.ParentNetIdSingle
clazzFields inherited from class alexiil.mc.lib.net.TreeNetIdBase
DYNAMIC_LENGTH, fullName, length, name, totalLength -
Constructor Summary
ConstructorsConstructorDescriptionParentNetIdDuel(ParentNetIdSingle<Parent> parent, String name, Class<T> clazz) ParentNetIdDuel(ParentNetIdSingle<Parent> parent, String name, Class<T> clazz, int length) -
Method Summary
Modifier and TypeMethodDescriptionprotected abstract ParentextractParent(T value) protected Stringprotected final TreadContext(NetByteBuf buffer, IMsgReadCtx ctx) protected abstract TreadContext(NetByteBuf buffer, IMsgReadCtx ctx, Parent parentValue) protected final voidwriteContext(NetByteBuf buffer, IMsgWriteCtx ctx, T value) protected abstract voidwriteContext0(NetByteBuf buffer, IMsgWriteCtx ctx, T value) protected voidwriteDynamicContext(CheckingNetByteBuf buffer, IMsgWriteCtx ctx, T value, List<TreeNetIdBase> resolvedPath) Methods inherited from class alexiil.mc.lib.net.ParentNetIdSingle
child, extractor, idData, idData, idSignal, readKey, subType, writeKeyMethods inherited from class alexiil.mc.lib.net.TreeNetIdBase
equals, getRealClassName, hasFixedLength, hashCode, toString
-
Field Details
-
parent
-
-
Constructor Details
-
ParentNetIdDuel
-
ParentNetIdDuel
-
-
Method Details
-
getPrintableName
- Overrides:
getPrintableNamein classParentNetIdSingle<T>
-
writeContext
- Specified by:
writeContextin classParentNetIdSingle<T>
-
writeDynamicContext
protected void writeDynamicContext(CheckingNetByteBuf buffer, IMsgWriteCtx ctx, T value, List<TreeNetIdBase> resolvedPath) - Overrides:
writeDynamicContextin classParentNetIdSingle<T>
-
extractParent
-
writeContext0
-
readContext
- Specified by:
readContextin classParentNetIdSingle<T>- Returns:
- The read value, or null if the parent couldn't be read.
- Throws:
InvalidInputDataException- if the byte buffer contained invalid data.
-
readContext
protected abstract T readContext(NetByteBuf buffer, IMsgReadCtx ctx, Parent parentValue) throws InvalidInputDataException - Returns:
- The read value.
- Throws:
InvalidInputDataException- if the byte buffer contained invalid data.
-