jnr.ffi
Class Struct.EnumLong<E extends Enum<E>>

java.lang.Object
  extended by jnr.ffi.Struct.Member
      extended by jnr.ffi.Struct.NumberField
          extended by jnr.ffi.Struct.EnumField<E>
              extended by jnr.ffi.Struct.EnumLong<E>
Enclosing class:
Struct

public class Struct.EnumLong<E extends Enum<E>>
extends Struct.EnumField<E>


Field Summary
 
Fields inherited from class jnr.ffi.Struct.EnumField
enumClass
 
Fields inherited from class jnr.ffi.Struct.NumberField
type
 
Constructor Summary
Struct.EnumLong(Class<E> enumClass)
           
 
Method Summary
 E get()
          Gets a java Enum value representing the native integer value.
 int intValue()
          Returns a int representation of this Number.
 long longValue()
          Returns a long representation of this Number.
 void set(E value)
           
 void set(Number value)
          Sets the field to a new value.
 
Methods inherited from class jnr.ffi.Struct.EnumField
toString
 
Methods inherited from class jnr.ffi.Struct.NumberField
byteValue, doubleValue, floatValue, getMemory, offset, shortValue, struct
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Struct.EnumLong

public Struct.EnumLong(Class<E> enumClass)
Method Detail

get

public final E get()
Description copied from class: Struct.EnumField
Gets a java Enum value representing the native integer value.

Specified by:
get in class Struct.EnumField<E extends Enum<E>>
Returns:
a java Enum value.

set

public final void set(E value)

set

public void set(Number value)
Description copied from class: Struct.NumberField
Sets the field to a new value.

Specified by:
set in class Struct.NumberField
Parameters:
value - The new value.

intValue

public final int intValue()
Description copied from class: Struct.NumberField
Returns a int representation of this Number.

Specified by:
intValue in class Struct.NumberField
Returns:
a int value for this Number.

longValue

public final long longValue()
Description copied from class: Struct.NumberField
Returns a long representation of this Number.

Overrides:
longValue in class Struct.NumberField
Returns:
a long value for this Number.


Copyright © 2013. All Rights Reserved.