CADI.Server.Cache
Class JPCServerCache

java.lang.Object
  extended by CADI.Server.Cache.ServerCache
      extended by CADI.Server.Cache.JPCServerCache

public class JPCServerCache
extends ServerCache

Version:
1.3.3 2008/12/05
Author:
Group on Interactive Coding of Images (GICI)

Field Summary
private  int[][] BDResolutionPrecinctHeights
          Definition in CODParameters.precinctHeights
private  int[][] BDResolutionPrecinctWidths
          Definition in CODParameters.precinctWidths
(package private)  JP2LogicalTarget logicalTarget
          Is the logical target
private  int maxNumLayers
          Definition in CODParameters.numLayers.
protected  java.util.HashMap<java.lang.Long,java.util.ArrayList<int[][][]>> precinctsQualityLayers
          It is a hash table that storages the number of coding passes for each quality layer.
private  int tiles
           
private  int[] WTLevels
          Definition in CODParameters.WTLevels
private  int XOsize
          Definition in SIZParameters.XOsize
private  int xSize
          Definition in SIZParameters.xSize
private  int YOsize
          Definition in SIZParameters.YOsize
private  int ySize
          Definition in SIZParameters.ySize
private  int zSize
          Definition in SIZParameters.zSize
 
Fields inherited from class CADI.Server.Cache.ServerCache
isCompleteMainHeader, lengthOfMainHeaderSent, precinctDataBinLengths, precinctDataBinOffsets
 
Constructor Summary
JPCServerCache()
          Constructor.
 
Method Summary
 void createCache(ServerLogicalTarget logicalTarget)
          This method has to initialize all variables/structures that will be used in the next methods calls.
 void list(java.io.PrintStream out)
          Prints this JPC Server Cache fields out to the specified output stream.
 java.lang.String toString()
           
 void update(java.util.ArrayList<CacheDescriptor> descriptor)
          Updates the server cache with data client has sent or with data sent from the server to the client.
 
Methods inherited from class CADI.Server.Cache.ServerCache
addElementPrecinctDataBin, getMainHeaderSent, getPrecinctDataBinLength, getPrecinctDataBinOffset, isCompleteMainHeader, reset, update
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

logicalTarget

JP2LogicalTarget logicalTarget
Is the logical target


precinctsQualityLayers

protected java.util.HashMap<java.lang.Long,java.util.ArrayList<int[][][]>> precinctsQualityLayers
It is a hash table that storages the number of coding passes for each quality layer. The key of the hash is the unique data-bin identifier calculated as:
I = t + (c + s x num_components) + num_tiles
where,
  I is the unique identifier of the precinct within its codestream;
  t is the index (startin from 0) of the tile to which the precinct belongs;
  c is the index (starting from 0) of the image component to which the precinct belongs;
  s is a sequence number which identifies the precinct within its tile-component.
Values of the hash table are the number of coding passes from a precinct belonging to a quality layer.


XOsize

private int XOsize
Definition in SIZParameters.XOsize


YOsize

private int YOsize
Definition in SIZParameters.YOsize


tiles

private int tiles

zSize

private int zSize
Definition in SIZParameters.zSize


ySize

private int ySize
Definition in SIZParameters.ySize


xSize

private int xSize
Definition in SIZParameters.xSize


WTLevels

private int[] WTLevels
Definition in CODParameters.WTLevels


BDResolutionPrecinctWidths

private int[][] BDResolutionPrecinctWidths
Definition in CODParameters.precinctWidths


BDResolutionPrecinctHeights

private int[][] BDResolutionPrecinctHeights
Definition in CODParameters.precinctHeights


maxNumLayers

private int maxNumLayers
Definition in CODParameters.numLayers.

Constructor Detail

JPCServerCache

public JPCServerCache()
Constructor.

Method Detail

createCache

public void createCache(ServerLogicalTarget logicalTarget)
Description copied from class: ServerCache
This method has to initialize all variables/structures that will be used in the next methods calls.

This method will only be called once after the object is created.

Specified by:
createCache in class ServerCache

update

public void update(java.util.ArrayList<CacheDescriptor> descriptor)
Updates the server cache with data client has sent or with data sent from the server to the client.

Specified by:
update in class ServerCache

toString

public java.lang.String toString()
Overrides:
toString in class ServerCache

list

public void list(java.io.PrintStream out)
Prints this JPC Server Cache fields out to the specified output stream. This method is useful for debugging.

Overrides:
list in class ServerCache
Parameters:
out - an output stream.


CADI - Copyright (C) 2007
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

Group on Interactive Coding of Images (GICI) (contact)