Class TestDnsNameWithPortValue
- java.lang.Object
-
- org.ow2.authzforce.core.pdp.api.value.SimpleValue<V>
-
- org.ow2.authzforce.core.pdp.api.value.StringParseableValue<String>
-
- org.ow2.authzforce.core.pdp.testutil.ext.TestDnsNameWithPortValue
-
- All Implemented Interfaces:
org.ow2.authzforce.core.pdp.api.value.AttributeValue
,org.ow2.authzforce.core.pdp.api.value.PrimitiveValue
,org.ow2.authzforce.core.pdp.api.value.Value
public final class TestDnsNameWithPortValue extends org.ow2.authzforce.core.pdp.api.value.StringParseableValue<String>
Represents the dnsName-value datatype XACML Data Loss Prevention / Network Access Control (DLP/NAC) Profile Version 1.0. Edited by John Tolbert, Richard Hill, Crystal Hayes, David Brossard, Hal Lockhart, and Steven Legg. 16 February 2015. OASIS Committee Specification 01. http://docs.oasis-open.org/xacml/xacml-3.0-dlp-nac/v1.0/cs01/xacml-3.0-dlp-nac-v1.0-cs01.html. Latest version: http://docs.oasis-open.org/xacml/xacml-3.0-dlp-nac/v1.0/xacml-3.0-dlp-nac-v1.0.html.It is basically the same as XACML Core dnsName datatype except that the hostname may use a wildcard as left-most subdomain, and the part after ':' is limited to a port number only.
Used here for testing Authzforce datatype extension mechanism, i.e. plugging a custom simple datatype into the PDP engine.
- Version:
- $Id: $
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
TestDnsNameWithPortValue.Factory
-
Field Summary
Fields Modifier and Type Field Description static org.ow2.authzforce.core.pdp.api.value.AttributeDatatype<TestDnsNameWithPortValue>
DATATYPE
Data typestatic TestDnsNameWithPortValue.Factory
FACTORY
-
Constructor Summary
Constructors Constructor Description TestDnsNameWithPortValue(String val)
Returns a newDNSNameAttributeValue
that represents the name indicated by theString
provided.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(Object obj)
String
getHostName()
Returns the host name represented by this object.int
hashCode()
String
printXML()
-
Methods inherited from class org.ow2.authzforce.core.pdp.api.value.StringParseableValue
getXmlAttributes
-
-
-
-
Field Detail
-
DATATYPE
public static final org.ow2.authzforce.core.pdp.api.value.AttributeDatatype<TestDnsNameWithPortValue> DATATYPE
Data type
-
FACTORY
public static final TestDnsNameWithPortValue.Factory FACTORY
-
-
Constructor Detail
-
TestDnsNameWithPortValue
public TestDnsNameWithPortValue(String val) throws IllegalArgumentException
Returns a newDNSNameAttributeValue
that represents the name indicated by theString
provided.- Parameters:
val
- a string representing the name- Throws:
IllegalArgumentException
- if format ofval
does not comply with the dnsName datatype definition
-
-
Method Detail
-
getHostName
public String getHostName()
Returns the host name represented by this object. Used byTestDnsNameValueEqualFunction
- Returns:
- the host name
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classorg.ow2.authzforce.core.pdp.api.value.SimpleValue<String>
-
equals
public boolean equals(Object obj)
- Overrides:
equals
in classorg.ow2.authzforce.core.pdp.api.value.SimpleValue<String>
-
-