Package org.jcsp.net.settings

# Class Protocol

java.lang.Object
org.jcsp.net.settings.Protocol

public class Protocol extends Object
Used internally within the JCSP network infrastructure to represent a single protocol.

Author:
  Quickstone Technologies Limited

## Constructor Summary

Constructors
Constructor
Description
`Protocol(String protocolID, String protocolName, Class idClass, int position)`

## Method Summary

Modifier and Type
Method
Description
`void`
`addSetting(Setting setting)`
`void`
`addSpec(Spec spec)`
`boolean`
`equals(Object o)`
`Class`
`getIDClass()`
`String`
`getName()`
`int`
`getPosition()`
`String`
`getProtocolID()`
`Setting`
`getSetting(String name)`
`Setting[]`
`getSettings()`
`Spec[]`
`getSpecs()`
`int`
`hashCode()`
`void`
`removeSetting(Setting setting)`
`void`
`removeSpec(Spec spec)`
`String`
`toString()`

### Methods inherited from class java.lang.Object

`clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

## Constructor Details

### Protocol

public Protocol(String protocolID, String protocolName, Class idClass, int position)

## Method Details

### addSpec

public void addSpec(Spec spec)

### removeSpec

public void removeSpec(Spec spec)

### getSpecs

public Spec[] getSpecs()

### addSetting

public void addSetting(Setting setting)

### removeSetting

public void removeSetting(Setting setting)

### getSettings

public Setting[] getSettings()

### getSetting

public Setting getSetting(String name)

### getProtocolID

public String getProtocolID()

### getName

public String getName()

### getIDClass

public Class getIDClass()

### getPosition

public int getPosition()

### toString

public String toString()

Overrides:
  `toString` in class `Object`

### equals

public boolean equals(Object o)

Overrides:
  `equals` in class `Object`

### hashCode

public int hashCode()

Overrides:
  `hashCode` in class `Object`