com.j256.simplemagic.types
Class LocalLongDateType

java.lang.Object
  extended by com.j256.simplemagic.types.LongType
      extended by com.j256.simplemagic.types.IntegerType
          extended by com.j256.simplemagic.types.LocalDateType
              extended by com.j256.simplemagic.types.LocalLongDateType
All Implemented Interfaces:
MagicMatcher
Direct Known Subclasses:
UtcLongDateType

public class LocalLongDateType
extends LocalDateType

An 8-byte value interpreted as a UNIX-style date, but interpreted as local time rather than UTC.

Author:
graywatson

Field Summary
 
Fields inherited from class com.j256.simplemagic.types.LocalDateType
dateFormat
 
Fields inherited from class com.j256.simplemagic.types.LongType
endianConverter
 
Constructor Summary
LocalLongDateType(EndianType endianType)
           
 
Method Summary
protected  Date dateFromExtractedValue(long val)
           
 Long extractValueFromBytes(int offset, byte[] bytes)
          Extract the value from the bytes.
 
Methods inherited from class com.j256.simplemagic.types.LocalDateType
assisgnTimeZone, renderValue
 
Methods inherited from class com.j256.simplemagic.types.LongType
convertTestString, isMatch
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LocalLongDateType

public LocalLongDateType(EndianType endianType)
Method Detail

extractValueFromBytes

public Long extractValueFromBytes(int offset,
                                  byte[] bytes)
Description copied from interface: MagicMatcher
Extract the value from the bytes.

Specified by:
extractValueFromBytes in interface MagicMatcher
Overrides:
extractValueFromBytes in class IntegerType
Returns:
The object to be passed to MagicMatcher.isMatch(Object, Long, boolean, Object, int, byte[]) or null if not enough bytes.

dateFromExtractedValue

protected Date dateFromExtractedValue(long val)
Overrides:
dateFromExtractedValue in class LocalDateType


This content is licensed by Gray Watson under the Creative Commons Attribution-Share Alike 3.0 License.