public class AutomatedAgentType
extends java.lang.Object
AutomatedAgentsCore
,
AutomatedAgent
Modifier and Type | Field and Description |
---|---|
FullUtility |
m_fullUtility |
static int |
MAX_ISSUES |
static int |
NO_TYPE |
static int |
NO_VALUE |
static java.lang.String |
NOT_APPLICABLE_STR1 |
static int |
SIDE_A_TYPE |
static int |
SIDE_B_TYPE |
static int |
VERY_HIGH_NUMBER |
static int |
VERY_SMALL_NUMBER |
Constructor and Description |
---|
AutomatedAgentType()
Method name: AutomatedAgentType()
Goal: Initializes the agent
Input: None.
|
Modifier and Type | Method and Description |
---|---|
void |
calculateValues(AbstractAutomatedAgent abstractAgent,
int nCurrentTurn)
Calculate utility value, best agreement and worse agreement at time nTimePeriod.
|
int[] |
getAgreementIndices(java.lang.String sAgreementStr)
Get indices of a given agreement
|
java.lang.String |
getAgreementStr(int[] CurrentAgreementIdx)
Get String of agreement by issues indice
|
double |
getAgreementTypeEffect() |
double |
getAgreementValue(int[] CurrentAgreementIdx,
int nCurrentTurn)
Get value of a given agreement by issues indices for
a given turn
|
java.lang.String |
getBestAgreementStr()
Returns the best agreement as String value
|
double |
getBestAgreementValue() |
double |
getBestAgreementValue(int nCurrentTurn)
Returns the value of the best agreement in the current turn
|
int |
getIssuesNum()
Method name: getIssuesNum()
Goal: Return the number of issues in the negotiation
Input: None.
|
int |
getMaxIssueValue(int nIssueNum)
Return the maximal value for a given issue
|
double |
getOptOutValue() |
double |
getSQValue()
Return the status quo value
|
int |
getTotalAgreements()
Return the total number of agreements in the negotiation
|
java.lang.String |
getWorstAgreementStr()
Returns the worst agreement as String value
|
double |
getWorstAgreementValue() |
double |
getWorstAgreementValue(int nCurrentTurn)
Returns the value of the worst agreement in the current turn
|
void |
initializeBestAgreementIndices() |
void |
initializeWorstAgreementIndices() |
boolean |
isIssueValueNoAgreement(int nIssueNum,
int nIssueNumIdx)
Check whether an issue in the agreement has an N/A value
|
boolean |
isTypeOf(int nAgentType) |
void |
setAgentType(int nType)
Sets the agent type - either NO_TYPE,
SIDE_A_TYPE (Eng/Emp) or SIDE_B_TYPE (Zim/Job Can)
|
void |
setBestAgreementIndices(int[] currentAgreementIdx) |
void |
setBestAgreementValue(double value) |
void |
setName(java.lang.String sName)
Method name: setName()
Goal: Set the agent's name
Input: String - name.
|
void |
setWorstAgreementIndices(int[] currentAgreementIdx) |
void |
setWorstAgreementValue(double value) |
public static final java.lang.String NOT_APPLICABLE_STR1
public static final int VERY_SMALL_NUMBER
public static final int VERY_HIGH_NUMBER
public static final int MAX_ISSUES
public static final int NO_VALUE
public FullUtility m_fullUtility
public static final int NO_TYPE
public static final int SIDE_A_TYPE
public static final int SIDE_B_TYPE
public AutomatedAgentType()
public void setName(java.lang.String sName)
public int getIssuesNum()
public int getMaxIssueValue(int nIssueNum)
nIssueNum
- - the issue numberpublic int getTotalAgreements()
public void setAgentType(int nType)
nType
- - the agent's typepublic boolean isTypeOf(int nAgentType)
nAgentType
- - the agent's type
(either NO_TYPE, SIDE_A_TYPE (Eng/Emp) or SIDE_B_TYPE (Zim/Job Can)public double getSQValue()
public double getOptOutValue()
public double getBestAgreementValue(int nCurrentTurn)
nCurrentTurn
- - current turnpublic java.lang.String getBestAgreementStr()
public double getWorstAgreementValue(int nCurrentTurn)
nCurrentTurn
- - current turnpublic java.lang.String getWorstAgreementStr()
public double getAgreementValue(int[] CurrentAgreementIdx, int nCurrentTurn)
CurrentAgreementIdx
- - indices of the agreementnCurrentTurn
- - the current turnpublic java.lang.String getAgreementStr(int[] CurrentAgreementIdx)
CurrentAgreementIdx
- - indices of the agreementpublic boolean isIssueValueNoAgreement(int nIssueNum, int nIssueNumIdx)
nIssueNum
- - the issue numbernIssueIdx
- - the issue indexpublic int[] getAgreementIndices(java.lang.String sAgreementStr)
sAgreementStr
- - the agreement as stringpublic void calculateValues(AbstractAutomatedAgent abstractAgent, int nCurrentTurn)
nTimePeriod
- - the time period for the agreementpublic double getBestAgreementValue()
public void setBestAgreementValue(double value)
public double getWorstAgreementValue()
public void setWorstAgreementValue(double value)
public void initializeBestAgreementIndices()
public void initializeWorstAgreementIndices()
public double getAgreementTypeEffect()
public void setBestAgreementIndices(int[] currentAgreementIdx)
public void setWorstAgreementIndices(int[] currentAgreementIdx)