@HashCodeAndEqualsPlugin.Enhance public static class NamingStrategy.SuffixingRandom extends NamingStrategy.Suffixing
$ sign is included into the name to improve readability. As an exception,
types that subclass classes from the java.** packages are prefixed with a given package. This is
necessary as it is illegal to define non-bootstrap classes in this name space. The same strategy is applied
when subclassing a signed type which is equally illegal.| Modifier and Type | Class and Description |
|---|---|
static interface |
NamingStrategy.SuffixingRandom.BaseNameResolver
Deprecated.
|
NamingStrategy.AbstractBase, NamingStrategy.PrefixingRandom, NamingStrategy.Suffixing, NamingStrategy.SuffixingRandomBYTE_BUDDY_RENAME_PACKAGE, NO_PREFIX| Constructor and Description |
|---|
SuffixingRandom(String suffix)
Creates an immutable naming strategy with a given suffix but moves types that subclass types within
the
java.lang package into Byte Buddy's package namespace. |
SuffixingRandom(String suffix,
NamingStrategy.Suffixing.BaseNameResolver baseNameResolver)
Creates an immutable naming strategy with a given suffix but moves types that subclass types within
the
java.lang package into Byte Buddy's package namespace. |
SuffixingRandom(String suffix,
NamingStrategy.Suffixing.BaseNameResolver baseNameResolver,
String javaLangPackagePrefix)
Creates an immutable naming strategy with a given suffix but moves types that subclass types within
the
java.lang package into a given namespace. |
SuffixingRandom(String suffix,
NamingStrategy.Suffixing.BaseNameResolver baseNameResolver,
String javaLangPackagePrefix,
RandomString randomString)
Creates an immutable naming strategy with a given suffix but moves types that subclass types within
the
java.lang package into a given namespace. |
SuffixingRandom(String suffix,
NamingStrategy.SuffixingRandom.BaseNameResolver baseNameResolver)
Deprecated.
|
SuffixingRandom(String suffix,
NamingStrategy.SuffixingRandom.BaseNameResolver baseNameResolver,
String javaLangPackagePrefix)
|
SuffixingRandom(String suffix,
NamingStrategy.SuffixingRandom.BaseNameResolver baseNameResolver,
String javaLangPackagePrefix,
RandomString randomString)
|
SuffixingRandom(String suffix,
String javaLangPackagePrefix)
Creates an immutable naming strategy with a given suffix but moves types that subclass types within
the
java.lang package into Byte Buddy's package namespace. |
| Modifier and Type | Method and Description |
|---|---|
protected String |
name(TypeDescription superClass)
Determines a new name when creating a new type that subclasses the provided type.
|
rebase, redefine, subclasspublic SuffixingRandom(String suffix)
java.lang package into Byte Buddy's package namespace. All names are derived from the
unnamed type's super type.suffix - The suffix for the generated class.public SuffixingRandom(String suffix, String javaLangPackagePrefix)
java.lang package into Byte Buddy's package namespace.suffix - The suffix for the generated class.javaLangPackagePrefix - The fallback namespace for type's that subclass types within the
java.* namespace. If The prefix is set to the empty string,
no prefix is added.@Deprecated public SuffixingRandom(String suffix, NamingStrategy.SuffixingRandom.BaseNameResolver baseNameResolver)
SuffixingRandom(String, NamingStrategy.Suffixing.BaseNameResolver).java.lang package into Byte Buddy's package namespace.suffix - The suffix for the generated class.baseNameResolver - The base name resolver that is queried for locating the base name.public SuffixingRandom(String suffix, NamingStrategy.Suffixing.BaseNameResolver baseNameResolver)
java.lang package into Byte Buddy's package namespace.suffix - The suffix for the generated class.baseNameResolver - The base name resolver that is queried for locating the base name.@Deprecated public SuffixingRandom(String suffix, NamingStrategy.SuffixingRandom.BaseNameResolver baseNameResolver, String javaLangPackagePrefix)
java.lang package into a given namespace.suffix - The suffix for the generated class.baseNameResolver - The base name resolver that is queried for locating the base name.javaLangPackagePrefix - The fallback namespace for type's that subclass types within the
java.* namespace. If The prefix is set to the empty string,
no prefix is added.public SuffixingRandom(String suffix, NamingStrategy.Suffixing.BaseNameResolver baseNameResolver, String javaLangPackagePrefix)
java.lang package into a given namespace.suffix - The suffix for the generated class.baseNameResolver - The base name resolver that is queried for locating the base name.javaLangPackagePrefix - The fallback namespace for type's that subclass types within the
java.* namespace. If The prefix is set to the empty string,
no prefix is added.@Deprecated public SuffixingRandom(String suffix, NamingStrategy.SuffixingRandom.BaseNameResolver baseNameResolver, String javaLangPackagePrefix, RandomString randomString)
SuffixingRandom(String, NamingStrategy.Suffixing.BaseNameResolver, String, RandomString).java.lang package into a given namespace.suffix - The suffix for the generated class.baseNameResolver - The base name resolver that is queried for locating the base name.javaLangPackagePrefix - The fallback namespace for type's that subclass types within the
java.* namespace. If The prefix is set to the empty string,
no prefix is added.randomString - The random string instance to use.public SuffixingRandom(String suffix, NamingStrategy.Suffixing.BaseNameResolver baseNameResolver, String javaLangPackagePrefix, RandomString randomString)
java.lang package into a given namespace.suffix - The suffix for the generated class.baseNameResolver - The base name resolver that is queried for locating the base name.javaLangPackagePrefix - The fallback namespace for type's that subclass types within the
java.* namespace. If The prefix is set to the empty string,
no prefix is added.randomString - The random string instance to use.protected String name(TypeDescription superClass)
NamingStrategy.AbstractBasename in class NamingStrategy.SuffixingsuperClass - The super type of the created type.Copyright © 2014–2024. All rights reserved.