org.hd.d.pg2k.webSvr.threeD
Class LightweightMetaDataFetchInterface.GalleryBasicMetaData

java.lang.Object
  extended by org.hd.d.pg2k.webSvr.threeD.LightweightMetaDataFetchInterface.GalleryBasicMetaData
Enclosing interface:
LightweightMetaDataFetchInterface

public static final class LightweightMetaDataFetchInterface.GalleryBasicMetaData
extends java.lang.Object

Immutable store of the most basic Gallery meta-data. This contains a hash over the Gallery contents that should change whenever the set of exhibits in the Gallery changes, and a (non-negative) count of exhibits in the Gallery.

This also contains an expected maximum validity period for this and related mata-data fetched through this interface, ie within what short of time it should be revalidated or discarded.


Field Summary
static LightweightMetaDataFetchInterface.GalleryBasicMetaData EMPTY
          Default/empty instance.
 int exhibitCount
          Count of exhibits in the Gallery; non-negative.
 long exhibitSetHash
          Hash over exhibit set.
 int metaDataMaxCacheLifeMs
          Validity period (maximum cache time) in milliseconds; non-negative.
 
Constructor Summary
LightweightMetaDataFetchInterface.GalleryBasicMetaData(long hash, int count, int cacheMs)
          Create an instance.
 
Method Summary
static LightweightMetaDataFetchInterface.GalleryBasicMetaData fromWireString(java.lang.String s)
          Create an instance parsed from on-the-wire format; never null.
 java.lang.String toString()
          Human-readable string format.
 java.lang.String toWireString()
          Convert to String for suitable to use on the wire; pure printable ASCII.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

exhibitSetHash

public final long exhibitSetHash
Hash over exhibit set.


exhibitCount

public final int exhibitCount
Count of exhibits in the Gallery; non-negative.


metaDataMaxCacheLifeMs

public final int metaDataMaxCacheLifeMs
Validity period (maximum cache time) in milliseconds; non-negative.


EMPTY

public static final LightweightMetaDataFetchInterface.GalleryBasicMetaData EMPTY
Default/empty instance.

Constructor Detail

LightweightMetaDataFetchInterface.GalleryBasicMetaData

public LightweightMetaDataFetchInterface.GalleryBasicMetaData(long hash,
                                                              int count,
                                                              int cacheMs)
Create an instance. The exhibit count and cache time must be non-negative.

Method Detail

fromWireString

public static LightweightMetaDataFetchInterface.GalleryBasicMetaData fromWireString(java.lang.String s)
                                                                             throws java.lang.IllegalArgumentException
Create an instance parsed from on-the-wire format; never null.

Parameters:
s - value as generated by toWireString(); never null
Returns:
instance; never null
Throws:
java.lang.IllegalArgumentException - if input String is invalid

toWireString

public java.lang.String toWireString()
Convert to String for suitable to use on the wire; pure printable ASCII.


toString

public java.lang.String toString()
Human-readable string format.

Overrides:
toString in class java.lang.Object

DHD Multimedia Gallery V1.57.21

Copyright (c) 1996-2011, Damon Hart-Davis. All rights reserved.