Class ResourceLocation
- java.lang.Object
-
- com.vladsch.flexmark.test.util.spec.ResourceLocation
-
public class ResourceLocation extends java.lang.Object
-
-
Field Summary
Fields Modifier and Type Field Description private @NotNull java.lang.String
fileUrl
static ResourceLocation
NULL
private @NotNull java.lang.String
resolvedResourcePath
private @NotNull java.lang.Class<?>
resourceClass
private @NotNull java.lang.String
resourcePath
-
Constructor Summary
Constructors Modifier Constructor Description ResourceLocation(@NotNull java.lang.Class<?> resourceClass, @NotNull java.lang.String resourcePath, @NotNull java.lang.String fileUrl)
private
ResourceLocation(@NotNull java.lang.Class<?> resourceClass, @NotNull java.lang.String resourcePath, @NotNull java.lang.String fileUrl, @NotNull java.lang.String resolvedResourcePath)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object o)
@NotNull java.lang.String
getFileDirectoryUrl()
@NotNull java.lang.String
getFileUrl()
@NotNull java.lang.String
getFileUrl(int lineNumber)
@NotNull java.lang.String
getResolvedResourcePath()
@NotNull java.lang.Class<?>
getResourceClass()
@NotNull java.io.InputStream
getResourceInputStream()
static @NotNull java.io.InputStream
getResourceInputStream(@NotNull ResourceLocation location)
@NotNull java.lang.String
getResourcePath()
@NotNull java.lang.String
getResourceText()
static @NotNull java.lang.String
getResourceText(@NotNull ResourceLocation location)
int
hashCode()
boolean
isNull()
static @NotNull ResourceLocation
of(@NotNull java.lang.Class<?> resourceClass, @NotNull java.lang.String resourcePath)
static @NotNull ResourceLocation
of(@NotNull java.lang.Class<?> resourceClass, @NotNull java.lang.String resourcePath, @NotNull java.lang.String fileUrl)
static @NotNull ResourceLocation
of(@NotNull java.lang.String resourcePath)
java.lang.String
toString()
@NotNull ResourceLocation
withFileUrl(@NotNull java.lang.String fileUrl)
@NotNull ResourceLocation
withResolvedResourcePath(@NotNull java.lang.String resolvedResourcePath)
@NotNull ResourceLocation
withResourceClass(@NotNull java.lang.Class<?> resourceClass)
@NotNull ResourceLocation
withResourcePath(@NotNull java.lang.String resourcePath)
-
-
-
Field Detail
-
NULL
public static final ResourceLocation NULL
-
resourceClass
@NotNull private final @NotNull java.lang.Class<?> resourceClass
-
resourcePath
@NotNull private final @NotNull java.lang.String resourcePath
-
fileUrl
@NotNull private final @NotNull java.lang.String fileUrl
-
resolvedResourcePath
@NotNull private final @NotNull java.lang.String resolvedResourcePath
-
-
Constructor Detail
-
ResourceLocation
public ResourceLocation(@NotNull @NotNull java.lang.Class<?> resourceClass, @NotNull @NotNull java.lang.String resourcePath, @NotNull @NotNull java.lang.String fileUrl)
-
ResourceLocation
private ResourceLocation(@NotNull @NotNull java.lang.Class<?> resourceClass, @NotNull @NotNull java.lang.String resourcePath, @NotNull @NotNull java.lang.String fileUrl, @NotNull @NotNull java.lang.String resolvedResourcePath)
-
-
Method Detail
-
getResourceClass
@NotNull public @NotNull java.lang.Class<?> getResourceClass()
-
getResourcePath
@NotNull public @NotNull java.lang.String getResourcePath()
-
getFileUrl
@NotNull public @NotNull java.lang.String getFileUrl()
-
getFileDirectoryUrl
@NotNull public @NotNull java.lang.String getFileDirectoryUrl()
-
getFileUrl
@NotNull public @NotNull java.lang.String getFileUrl(int lineNumber)
-
getResolvedResourcePath
@NotNull public @NotNull java.lang.String getResolvedResourcePath()
-
isNull
public boolean isNull()
-
getResourceInputStream
@NotNull public @NotNull java.io.InputStream getResourceInputStream()
-
getResourceText
@NotNull public @NotNull java.lang.String getResourceText()
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equals
in classjava.lang.Object
-
withResourceClass
@NotNull public @NotNull ResourceLocation withResourceClass(@NotNull @NotNull java.lang.Class<?> resourceClass)
-
withResourcePath
@NotNull public @NotNull ResourceLocation withResourcePath(@NotNull @NotNull java.lang.String resourcePath)
-
withFileUrl
@NotNull public @NotNull ResourceLocation withFileUrl(@NotNull @NotNull java.lang.String fileUrl)
-
withResolvedResourcePath
@NotNull public @NotNull ResourceLocation withResolvedResourcePath(@NotNull @NotNull java.lang.String resolvedResourcePath)
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
of
@NotNull public static @NotNull ResourceLocation of(@NotNull @NotNull java.lang.String resourcePath)
-
of
@NotNull public static @NotNull ResourceLocation of(@NotNull @NotNull java.lang.Class<?> resourceClass, @NotNull @NotNull java.lang.String resourcePath)
-
of
@NotNull public static @NotNull ResourceLocation of(@NotNull @NotNull java.lang.Class<?> resourceClass, @NotNull @NotNull java.lang.String resourcePath, @NotNull @NotNull java.lang.String fileUrl)
-
getResourceText
@NotNull public static @NotNull java.lang.String getResourceText(@NotNull @NotNull ResourceLocation location)
-
getResourceInputStream
@NotNull public static @NotNull java.io.InputStream getResourceInputStream(@NotNull @NotNull ResourceLocation location)
-
-