public class ResourcePattern extends java.lang.Object implements java.lang.Comparable<ResourcePattern>
AccessRule
. This uses
resource types that are not pre-defined, enabling this class to be used for defining
rules in different components.Modifier and Type | Field and Description |
---|---|
static ResourcePattern |
ALL |
Constructor and Description |
---|
ResourcePattern(ResourceType resourceType,
java.lang.String name,
org.apache.kafka.common.resource.PatternType patternType) |
ResourcePattern(java.lang.String type,
java.lang.String name,
org.apache.kafka.common.resource.PatternType patternType) |
Modifier and Type | Method and Description |
---|---|
static ResourcePattern |
all(ResourceType resourceType) |
int |
compareTo(ResourcePattern other) |
boolean |
equals(java.lang.Object o) |
static ResourcePattern |
from(org.apache.kafka.common.resource.ResourcePattern resourcePattern) |
static ResourcePattern |
from(org.apache.kafka.common.resource.ResourcePatternFilter resourcePattern) |
int |
hashCode() |
java.lang.String |
name() |
org.apache.kafka.common.resource.PatternType |
patternType() |
ResourceType |
resourceType() |
static org.apache.kafka.common.resource.ResourcePattern |
to(ResourcePattern resourcePattern) |
ResourcePatternFilter |
toFilter() |
java.lang.String |
toString() |
public static final ResourcePattern ALL
public ResourcePattern(java.lang.String type, java.lang.String name, org.apache.kafka.common.resource.PatternType patternType)
public ResourcePattern(ResourceType resourceType, java.lang.String name, org.apache.kafka.common.resource.PatternType patternType)
public java.lang.String name()
public ResourceType resourceType()
public org.apache.kafka.common.resource.PatternType patternType()
public ResourcePatternFilter toFilter()
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public int compareTo(ResourcePattern other)
compareTo
in interface java.lang.Comparable<ResourcePattern>
public java.lang.String toString()
toString
in class java.lang.Object
public static ResourcePattern all(ResourceType resourceType)
public static ResourcePattern from(org.apache.kafka.common.resource.ResourcePattern resourcePattern)
public static org.apache.kafka.common.resource.ResourcePattern to(ResourcePattern resourcePattern)
public static ResourcePattern from(org.apache.kafka.common.resource.ResourcePatternFilter resourcePattern)