iaik.tc.tss.api.structs.tpm
Class TcTpmVersion

Object
  extended by TcBasicTypeDecoder
      extended by TcCompositeTypeDecoder
          extended by TcTpmVersion
Direct Known Subclasses:
TcTpmStructVer

public class TcTpmVersion
extends TcCompositeTypeDecoder

The TPM_VERSION allows the TPM to communicate with outside entities as to the version of the TPM. This structure is set by the TPM and included in structures that are maintained long term outside of the TPM.

TCPA 1.1b Main Specification, page number:
25

Field Summary
static TcTpmVersion TPM_V1_1
          This constant can be used for TPM 1.1 version comparisons
static TcTpmVersion TPM_V1_2
          This constant can be used for TPM 1.2 version comparisons
 
Constructor Summary
TcTpmVersion()
          Constructor - see superclass for details
TcTpmVersion(TcBlobData blob)
          Constructor - see superclass for details
TcTpmVersion(TcBlobData blob, int offset)
          Constructor - see superclass for details
TcTpmVersion(TcCompositeTypeDecoder composite)
          Constructor - see superclass for details
 
Method Summary
 boolean equalsMinMaj(Object obj)
          This method returns true if the two major and minor version numbers are equal, false otherwise.
 boolean equalsRevMinMaj(Object obj)
          This method returns true if the tow major and minor revisions numbers are equal, false otherwise.
 TcBlobData getEncoded()
          This method encodes the TPM_VERSION as a byte blob.
 short getMajor()
          Returns contents of the major field.
 short getMinor()
          Returns contents of the minor field.
 short getRevMajor()
          Returns contents of the revMajor field.
 short getRevMinor()
          Returns contents of the revMinor field.
 void setMajor(short major)
          Sets the major field.
 void setMinor(short minor)
          Sets the minor field.
 void setRevMajor(short revMajor)
          Sets the revMajor field.
 void setRevMinor(short revMinor)
          Sets the revMinor field.
 String toString()
          This method returns a String representation of the object.
 
Methods inherited from class TcBasicTypeDecoder
decodeBoolean, decodeByte, decodeBytes, decodeBytes, decodeTpmAlgorithmId, decodeTpmAuthDataUsage, decodeTpmEncScheme, decodeTpmKeyFlags, decodeTpmKeyUsage, decodeTpmSigScheme, decodeTssAlgorithmId, decodeTssEncScheme, decodeTssEvenType, decodeTssFlag, decodeTssHandle, decodeTssHContext, decodeTssHEncData, decodeTssHHash, decodeTssHKey, decodeTssHObjet, decodeTssHPcrs, decodeTssHPolicy, decodeTssHPS, decodeTssHTpm, decodeTssKeyUsageId, decodeTssMigrationScheme, decodeTssResult, decodeTssSigScheme, decodeUINT16, decodeUINT32, decodeUINT64
 
Methods inherited from class Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

TPM_V1_1

public static final TcTpmVersion TPM_V1_1
This constant can be used for TPM 1.1 version comparisons


TPM_V1_2

public static final TcTpmVersion TPM_V1_2
This constant can be used for TPM 1.2 version comparisons

Constructor Detail

TcTpmVersion

public TcTpmVersion()
Constructor - see superclass for details


TcTpmVersion

public TcTpmVersion(TcBlobData blob)
Constructor - see superclass for details


TcTpmVersion

public TcTpmVersion(TcBlobData blob,
                    int offset)
Constructor - see superclass for details


TcTpmVersion

public TcTpmVersion(TcCompositeTypeDecoder composite)
Constructor - see superclass for details

Method Detail

getEncoded

public TcBlobData getEncoded()
This method encodes the TPM_VERSION as a byte blob.

Specified by:
getEncoded in class TcCompositeTypeDecoder
Returns:
byte blob to be passed to other layers (e.g. TSS)

toString

public String toString()
This method returns a String representation of the object.

Overrides:
toString in class TcCompositeTypeDecoder

equalsMinMaj

public boolean equalsMinMaj(Object obj)
This method returns true if the two major and minor version numbers are equal, false otherwise. Note: revMinor and revMajor are ignored by this method.


equalsRevMinMaj

public boolean equalsRevMinMaj(Object obj)
This method returns true if the tow major and minor revisions numbers are equal, false otherwise. Note: minor and major are ignored by this method (only revMinor and revMajor) are taken into account.


getMajor

public short getMajor()
Returns contents of the major field.


setMajor

public void setMajor(short major)
Sets the major field.


getMinor

public short getMinor()
Returns contents of the minor field.


setMinor

public void setMinor(short minor)
Sets the minor field.


getRevMajor

public short getRevMajor()
Returns contents of the revMajor field.


setRevMajor

public void setRevMajor(short revMajor)
Sets the revMajor field.


getRevMinor

public short getRevMinor()
Returns contents of the revMinor field.


setRevMinor

public void setRevMinor(short revMinor)
Sets the revMinor field.