Package org.ldaptive.ad.transcode
Class DeltaTimeValueTranscoder
- java.lang.Object
-
- org.ldaptive.transcode.AbstractStringValueTranscoder<Long>
-
- org.ldaptive.ad.transcode.DeltaTimeValueTranscoder
-
- All Implemented Interfaces:
ValueTranscoder<Long>
public class DeltaTimeValueTranscoder extends AbstractStringValueTranscoder<Long>
Decodes and encodes an active directory delta time value for use in an ldap attribute value.
-
-
Field Summary
Fields Modifier and Type Field Description private static long
ONE_HUNDRED_NANOSECOND_INTERVAL
Delta time uses 100-nanosecond intervals.
-
Constructor Summary
Constructors Constructor Description DeltaTimeValueTranscoder()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Long
decodeStringValue(String value)
Decodes the supplied ldap attribute value into a custom type.String
encodeStringValue(Long value)
Encodes the supplied value into an ldap attribute value.Class<Long>
getType()
Returns the type produced by this value transcoder.-
Methods inherited from class org.ldaptive.transcode.AbstractStringValueTranscoder
decodeBinaryValue, encodeBinaryValue
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.ldaptive.transcode.ValueTranscoder
decoder, encoder
-
-
-
-
Field Detail
-
ONE_HUNDRED_NANOSECOND_INTERVAL
private static final long ONE_HUNDRED_NANOSECOND_INTERVAL
Delta time uses 100-nanosecond intervals. For conversion purposes this is 1x10^6 / 100.- See Also:
- Constant Field Values
-
-
Method Detail
-
decodeStringValue
public Long decodeStringValue(String value)
Description copied from interface:ValueTranscoder
Decodes the supplied ldap attribute value into a custom type.- Parameters:
value
- to decode- Returns:
- decoded value
-
encodeStringValue
public String encodeStringValue(Long value)
Description copied from interface:ValueTranscoder
Encodes the supplied value into an ldap attribute value.- Parameters:
value
- to encode- Returns:
- encoded value
-
getType
public Class<Long> getType()
Description copied from interface:ValueTranscoder
Returns the type produced by this value transcoder.- Returns:
- type produced by this value transcoder
-
-