org.jdiameter.common.impl.validation
Class AvpRepresentation

java.lang.Object
  extended by org.jdiameter.common.impl.validation.AvpRepresentation

public class AvpRepresentation
extends java.lang.Object

Start time:10:50:39 2009-05-26
Project: diameter-parent
Represents command avp, it stores info about presence, multiplicity, avp code, vendor.

Author:
Bartosz Baranowski , Alexandre Mendonca

Field Summary
static java.lang.String _MP_NOT_ALLOWED
           0 The AVP MUST NOT be present in the message.
static java.lang.String _MP_ONE
           
static java.lang.String _MP_ONE_AND_MORE
           
static java.lang.String _MP_ZERO_AND_MORE
           
static java.lang.String _MP_ZERO_OR_ONE
           
 
Constructor Summary
AvpRepresentation(int positionIndex, int code, long vendor, java.lang.String multiplicityIndicator, java.lang.String name)
           
AvpRepresentation(int code, long vendor)
           
 
Method Summary
 boolean equals(java.lang.Object obj)
           
static int get_FIX_POSITION_INDEX()
           
 int getCode()
           
 java.lang.String getMultiplicityIndicator()
           
 java.lang.String getName()
           
 int getPositionIndex()
           
 long getVendor()
           
 int hashCode()
           
 boolean isAllowed()
           
 boolean isCountValidForMultiplicity(int avpCount)
           
 boolean isPositionFixed()
           
 void markFixPosition(int index)
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

_MP_NOT_ALLOWED

public static final java.lang.String _MP_NOT_ALLOWED
 0     The AVP MUST NOT be present in the message.
 0+    Zero or more instances of the AVP MAY be present in the
       message.
 0-1   Zero or one instance of the AVP MAY be present in the
       message.  It is considered an error if there are more than
       one instance of the AVP.
 1     One instance of the AVP MUST be present in the message.
 1+    At least one instance of the AVP MUST be present in the
       message.
 

See Also:
Constant Field Values

_MP_ZERO_AND_MORE

public static final java.lang.String _MP_ZERO_AND_MORE
See Also:
Constant Field Values

_MP_ZERO_OR_ONE

public static final java.lang.String _MP_ZERO_OR_ONE
See Also:
Constant Field Values

_MP_ONE

public static final java.lang.String _MP_ONE
See Also:
Constant Field Values

_MP_ONE_AND_MORE

public static final java.lang.String _MP_ONE_AND_MORE
See Also:
Constant Field Values
Constructor Detail

AvpRepresentation

public AvpRepresentation(int code,
                         long vendor)

AvpRepresentation

public AvpRepresentation(int positionIndex,
                         int code,
                         long vendor,
                         java.lang.String multiplicityIndicator,
                         java.lang.String name)
Method Detail

isPositionFixed

public boolean isPositionFixed()

markFixPosition

public void markFixPosition(int index)

isCountValidForMultiplicity

public boolean isCountValidForMultiplicity(int avpCount)

get_FIX_POSITION_INDEX

public static int get_FIX_POSITION_INDEX()

getPositionIndex

public int getPositionIndex()

getCode

public int getCode()

getVendor

public long getVendor()

isAllowed

public boolean isAllowed()

getMultiplicityIndicator

public java.lang.String getMultiplicityIndicator()

getName

public java.lang.String getName()

toString

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

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class java.lang.Object


Copyright © 2009. All Rights Reserved.