-
-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* add unknown devices for multiserver * generate flatbuffer * add to enum * add a way to forget devices * add to enum rpc
- Loading branch information
Showing
27 changed files
with
1,351 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
59 changes: 59 additions & 0 deletions
59
protocol/java/src/solarxr_protocol/rpc/AddUnknownDeviceRequest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
// automatically generated by the FlatBuffers compiler, do not modify | ||
|
||
package solarxr_protocol.rpc; | ||
|
||
import java.nio.*; | ||
import java.lang.*; | ||
import java.util.*; | ||
import com.google.flatbuffers.*; | ||
|
||
@SuppressWarnings("unused") | ||
public final class AddUnknownDeviceRequest extends Table { | ||
public static void ValidateVersion() { Constants.FLATBUFFERS_22_10_26(); } | ||
public static AddUnknownDeviceRequest getRootAsAddUnknownDeviceRequest(ByteBuffer _bb) { return getRootAsAddUnknownDeviceRequest(_bb, new AddUnknownDeviceRequest()); } | ||
public static AddUnknownDeviceRequest getRootAsAddUnknownDeviceRequest(ByteBuffer _bb, AddUnknownDeviceRequest obj) { _bb.order(ByteOrder.LITTLE_ENDIAN); return (obj.__assign(_bb.getInt(_bb.position()) + _bb.position(), _bb)); } | ||
public void __init(int _i, ByteBuffer _bb) { __reset(_i, _bb); } | ||
public AddUnknownDeviceRequest __assign(int _i, ByteBuffer _bb) { __init(_i, _bb); return this; } | ||
|
||
public String macAddress() { int o = __offset(4); return o != 0 ? __string(o + bb_pos) : null; } | ||
public ByteBuffer macAddressAsByteBuffer() { return __vector_as_bytebuffer(4, 1); } | ||
public ByteBuffer macAddressInByteBuffer(ByteBuffer _bb) { return __vector_in_bytebuffer(_bb, 4, 1); } | ||
|
||
public static int createAddUnknownDeviceRequest(FlatBufferBuilder builder, | ||
int macAddressOffset) { | ||
builder.startTable(1); | ||
AddUnknownDeviceRequest.addMacAddress(builder, macAddressOffset); | ||
return AddUnknownDeviceRequest.endAddUnknownDeviceRequest(builder); | ||
} | ||
|
||
public static void startAddUnknownDeviceRequest(FlatBufferBuilder builder) { builder.startTable(1); } | ||
public static void addMacAddress(FlatBufferBuilder builder, int macAddressOffset) { builder.addOffset(0, macAddressOffset, 0); } | ||
public static int endAddUnknownDeviceRequest(FlatBufferBuilder builder) { | ||
int o = builder.endTable(); | ||
return o; | ||
} | ||
|
||
public static final class Vector extends BaseVector { | ||
public Vector __assign(int _vector, int _element_size, ByteBuffer _bb) { __reset(_vector, _element_size, _bb); return this; } | ||
|
||
public AddUnknownDeviceRequest get(int j) { return get(new AddUnknownDeviceRequest(), j); } | ||
public AddUnknownDeviceRequest get(AddUnknownDeviceRequest obj, int j) { return obj.__assign(__indirect(__element(j), bb), bb); } | ||
} | ||
public AddUnknownDeviceRequestT unpack() { | ||
AddUnknownDeviceRequestT _o = new AddUnknownDeviceRequestT(); | ||
unpackTo(_o); | ||
return _o; | ||
} | ||
public void unpackTo(AddUnknownDeviceRequestT _o) { | ||
String _oMacAddress = macAddress(); | ||
_o.setMacAddress(_oMacAddress); | ||
} | ||
public static int pack(FlatBufferBuilder builder, AddUnknownDeviceRequestT _o) { | ||
if (_o == null) return 0; | ||
int _macAddress = _o.getMacAddress() == null ? 0 : builder.createString(_o.getMacAddress()); | ||
return createAddUnknownDeviceRequest( | ||
builder, | ||
_macAddress); | ||
} | ||
} | ||
|
22 changes: 22 additions & 0 deletions
22
protocol/java/src/solarxr_protocol/rpc/AddUnknownDeviceRequestT.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
// automatically generated by the FlatBuffers compiler, do not modify | ||
|
||
package solarxr_protocol.rpc; | ||
|
||
import java.nio.*; | ||
import java.lang.*; | ||
import java.util.*; | ||
import com.google.flatbuffers.*; | ||
|
||
public class AddUnknownDeviceRequestT { | ||
private String macAddress; | ||
|
||
public String getMacAddress() { return macAddress; } | ||
|
||
public void setMacAddress(String macAddress) { this.macAddress = macAddress; } | ||
|
||
|
||
public AddUnknownDeviceRequestT() { | ||
this.macAddress = null; | ||
} | ||
} | ||
|
Oops, something went wrong.