public class ClassPathAccess extends BaseAccess implements AvatarAccess
AvatarAccess
interface by means of a JAR
on the JVM class path. This JAR must contain an empty class called
<avatar-name>.Access
which resides in the same folder as
the avatar definition files and whose sole purpose is to define
a resource base against which these files may be loaded.
This class is a concrete subclass of BaseAccess
, whose
AvatarData
is populated via the JAR as just described.Constructor and Description |
---|
ClassPathAccess(java.lang.String avname)
Constructs a class path based avatar access object for the given
avatar name.
|
Modifier and Type | Method and Description |
---|---|
static java.lang.Class<?> |
getAccessClass(java.lang.String rbname)
Returns the Java access class for the given resource base name
(typically an avatar name).
|
static java.lang.String |
getResourceBaseURL(java.lang.Class<?> accessclass)
A utility method returning a (
jar:... resource base URL that
contains the given Java access class, which is assumed to be in
a class file named Access.class . |
static java.lang.String |
getResourceBaseURL(java.lang.String rbname)
A utility method returning a (
jar:... resource base URL
for the given resource base name (typically an avatar name). |
asdData, avatarDefStream, avatarDefURL, avatarName, baseURL, configData, nonmanualsData, terminateAccess
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
asdData, avatarDefStream, avatarDefURL, avatarName, baseURL, configData, nonmanualsData, terminateAccess
public ClassPathAccess(java.lang.String avname) throws AvatarDataException
AvatarDataException
public static java.lang.String getResourceBaseURL(java.lang.String rbname)
jar:...
resource base URL
for the given resource base name (typically an avatar name).
The resource base is expected to be located in the JAR on the JVM
class path, and to be the base for a class in that jar named
<rbname>.Access
(where <rbname>
denotes the actual
parameter string).public static java.lang.String getResourceBaseURL(java.lang.Class<?> accessclass)
jar:...
resource base URL that
contains the given Java access class, which is assumed to be in
a class file named Access.class
.public static java.lang.Class<?> getAccessClass(java.lang.String rbname)
Access
in the Java package with the given resource base name, that is,
if <rbname>
is the actual parameter string then the
hierarchical resource name for the class is <rbname>.Access
.