public final class CoapOtherOptionAttributeImpl extends OtherOptionAttribute
| Constructor and Description |
|---|
CoapOtherOptionAttributeImpl(org.eclipse.californium.core.coap.Option option)
Copy constructor from Cf Option
|
CoapOtherOptionAttributeImpl(org.eclipse.californium.core.coap.option.OptionDefinition optionDef,
byte[] value)
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object obj)
Indicates whether some other object is "equal to" this.
|
String |
getAlias()
Get the alias of this other option.
|
OptionFormat |
getFormat()
Get the format of this other option.
|
int |
getLength()
Get the the length of the other option.
|
int |
getNumber()
Get the number of this other option.
|
InputStream |
getValue()
Get the value of this other option.
|
protected byte[] |
getValueAsBytes()
Get the value of this other option as byte array.
|
String |
getValueAsHex()
Get the option value as hexadecimal string.
|
long |
getValueAsNumber()
Get the value as number.
|
String |
getValueAsString()
Get value as UTF-8 string.
|
int |
hashCode()
Returns a hash code value for the object.
|
boolean |
isCritical()
Checks if option is critical.
|
boolean |
isEmpty()
Check if the option is empty.
|
boolean |
isNoCacheKey()
Checks if option with this number is a NoCacheKey option.
|
boolean |
isUnsafe()
Checks if option with this number is unsafe.
|
String |
toString()
Get the string representation.
|
public CoapOtherOptionAttributeImpl(org.eclipse.californium.core.coap.option.OptionDefinition optionDef,
byte[] value)
optionDef - The definition of the other option.value - The option value.public CoapOtherOptionAttributeImpl(org.eclipse.californium.core.coap.Option option)
option - The Cf Option to copy from.public String getAlias()
getAlias in class OtherOptionAttributepublic int getNumber()
getNumber in class OtherOptionAttributepublic OptionFormat getFormat()
getFormat in class OtherOptionAttributepublic boolean isEmpty()
isEmpty in class OtherOptionAttributepublic int getLength()
getLength in class OtherOptionAttributeprotected byte[] getValueAsBytes()
public InputStream getValue()
getValue in class OtherOptionAttributepublic long getValueAsNumber()
getValueAsNumber in class OtherOptionAttributepublic String getValueAsHex()
getValueAsHex in class OtherOptionAttributepublic String getValueAsString()
getValueAsString in class OtherOptionAttributepublic boolean isCritical()
isCritical in class OtherOptionAttributetrue if is option critical, otherwise false.public boolean isUnsafe()
isUnsafe in class OtherOptionAttributetrue if this is an unsafe option, otherwise false.public boolean isNoCacheKey()
isNoCacheKey in class OtherOptionAttributetrue if this is NoCacheKey option, otherwise false.public int hashCode()
public boolean equals(Object obj)
Copyright © 2019–2025 Teslanet.nl. All rights reserved.