All Downloads are FREE. Search and download functionalities are using the official Maven repository.

pl.grzeslowski.jsupla.protocol.api.structs.DigiglassValue Maven / Gradle / Ivy

package pl.grzeslowski.jsupla.protocol.api.structs;

import pl.grzeslowski.jsupla.protocol.api.structs.*;
import pl.grzeslowski.jsupla.protocol.api.types.ProtoWithSize;
import static pl.grzeslowski.jsupla.protocol.api.JavaConsts.*;
import static pl.grzeslowski.jsupla.protocol.api.Preconditions.*;
import static pl.grzeslowski.jsupla.protocol.api.consts.ProtoConsts.*;

/**
Original code:
typedef struct {
  unsigned char flags;
  unsigned char sectionCount;    // 1 - 16 Filled by server
  unsigned _supla_int16_t mask;  // bit mask. 0 - opaque, 1 - transparent
} TDigiglass_Value;
*/ @lombok.EqualsAndHashCode @lombok.ToString @javax.annotation.Generated(value="Struct original name: TDigiglass_Value", date = "2024-08-03T11:49:42.251Z[Etc/UTC]") public class DigiglassValue implements pl.grzeslowski.jsupla.protocol.api.types.ProtoWithSize { /** * unsigned byte */ public final short flags; /** * 1 - 16 Filled by server *

* unsigned byte */ public final short sectionCount; /** * bit mask. 0 - opaque, 1 - transparent *

* unsigned short */ public final int mask; public DigiglassValue(short flags, short sectionCount, int mask) { this.flags = unsigned(flags); this.sectionCount = unsigned(sectionCount); this.mask = unsigned(mask); } /* no call type */ @Override public int size() { return CHAR_SIZE // flags + CHAR_SIZE // sectionCount + SHORT_SIZE // mask ; } }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy