public final class StaticFilesHandler extends GeneratedMessageV3 implements StaticFilesHandlerOrBuilder
Files served directly to the user for a given URL, such as images, CSS
stylesheets, or JavaScript source files. Static file handlers describe which
files in the application directory are static files, and which URLs serve
them.
Protobuf type google.appengine.v1.StaticFilesHandler
Inherited Members
com.google.protobuf.GeneratedMessageV3.<ListT>makeMutableCopy(ListT)
Static Fields
APPLICATION_READABLE_FIELD_NUMBER
public static final int APPLICATION_READABLE_FIELD_NUMBER
Field Value |
---|
Type | Description |
int | |
EXPIRATION_FIELD_NUMBER
public static final int EXPIRATION_FIELD_NUMBER
Field Value |
---|
Type | Description |
int | |
HTTP_HEADERS_FIELD_NUMBER
public static final int HTTP_HEADERS_FIELD_NUMBER
Field Value |
---|
Type | Description |
int | |
MIME_TYPE_FIELD_NUMBER
public static final int MIME_TYPE_FIELD_NUMBER
Field Value |
---|
Type | Description |
int | |
PATH_FIELD_NUMBER
public static final int PATH_FIELD_NUMBER
Field Value |
---|
Type | Description |
int | |
REQUIRE_MATCHING_FILE_FIELD_NUMBER
public static final int REQUIRE_MATCHING_FILE_FIELD_NUMBER
Field Value |
---|
Type | Description |
int | |
UPLOAD_PATH_REGEX_FIELD_NUMBER
public static final int UPLOAD_PATH_REGEX_FIELD_NUMBER
Field Value |
---|
Type | Description |
int | |
Static Methods
getDefaultInstance()
public static StaticFilesHandler getDefaultInstance()
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
newBuilder()
public static StaticFilesHandler.Builder newBuilder()
newBuilder(StaticFilesHandler prototype)
public static StaticFilesHandler.Builder newBuilder(StaticFilesHandler prototype)
public static StaticFilesHandler parseDelimitedFrom(InputStream input)
public static StaticFilesHandler parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
parseFrom(byte[] data)
public static StaticFilesHandler parseFrom(byte[] data)
Parameter |
---|
Name | Description |
data | byte[]
|
parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
public static StaticFilesHandler parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
parseFrom(ByteString data)
public static StaticFilesHandler parseFrom(ByteString data)
parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
public static StaticFilesHandler parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
public static StaticFilesHandler parseFrom(CodedInputStream input)
public static StaticFilesHandler parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public static StaticFilesHandler parseFrom(InputStream input)
public static StaticFilesHandler parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
parseFrom(ByteBuffer data)
public static StaticFilesHandler parseFrom(ByteBuffer data)
parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
public static StaticFilesHandler parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
parser()
public static Parser<StaticFilesHandler> parser()
Methods
containsHttpHeaders(String key)
public boolean containsHttpHeaders(String key)
HTTP headers to use for all responses from these URLs.
map<string, string> http_headers = 3;
Parameter |
---|
Name | Description |
key | String
|
equals(Object obj)
public boolean equals(Object obj)
Parameter |
---|
Name | Description |
obj | Object
|
Overrides
getApplicationReadable()
public boolean getApplicationReadable()
Whether files should also be uploaded as code data. By default, files
declared in static file handlers are uploaded as static
data and are only served to end users; they cannot be read by the
application. If enabled, uploads are charged against both your code and
static data storage resource quotas.
bool application_readable = 7;
Returns |
---|
Type | Description |
boolean | The applicationReadable.
|
getDefaultInstanceForType()
public StaticFilesHandler getDefaultInstanceForType()
getExpiration()
public Duration getExpiration()
Time a static file served by this handler should be cached
by web proxies and browsers.
.google.protobuf.Duration expiration = 5;
Returns |
---|
Type | Description |
Duration | The expiration.
|
getExpirationOrBuilder()
public DurationOrBuilder getExpirationOrBuilder()
Time a static file served by this handler should be cached
by web proxies and browsers.
.google.protobuf.Duration expiration = 5;
getHttpHeaders()
public Map<String,String> getHttpHeaders()
getHttpHeadersCount()
public int getHttpHeadersCount()
HTTP headers to use for all responses from these URLs.
map<string, string> http_headers = 3;
Returns |
---|
Type | Description |
int | |
getHttpHeadersMap()
public Map<String,String> getHttpHeadersMap()
HTTP headers to use for all responses from these URLs.
map<string, string> http_headers = 3;
getHttpHeadersOrDefault(String key, String defaultValue)
public String getHttpHeadersOrDefault(String key, String defaultValue)
HTTP headers to use for all responses from these URLs.
map<string, string> http_headers = 3;
getHttpHeadersOrThrow(String key)
public String getHttpHeadersOrThrow(String key)
HTTP headers to use for all responses from these URLs.
map<string, string> http_headers = 3;
Parameter |
---|
Name | Description |
key | String
|
getMimeType()
public String getMimeType()
MIME type used to serve all files served by this handler.
Defaults to file-specific MIME types, which are derived from each file's
filename extension.
string mime_type = 4;
Returns |
---|
Type | Description |
String | The mimeType.
|
getMimeTypeBytes()
public ByteString getMimeTypeBytes()
MIME type used to serve all files served by this handler.
Defaults to file-specific MIME types, which are derived from each file's
filename extension.
string mime_type = 4;
Returns |
---|
Type | Description |
ByteString | The bytes for mimeType.
|
getParserForType()
public Parser<StaticFilesHandler> getParserForType()
Overrides
getPath()
Path to the static files matched by the URL pattern, from the
application root directory. The path can refer to text matched in groupings
in the URL pattern.
string path = 1;
Returns |
---|
Type | Description |
String | The path.
|
getPathBytes()
public ByteString getPathBytes()
Path to the static files matched by the URL pattern, from the
application root directory. The path can refer to text matched in groupings
in the URL pattern.
string path = 1;
Returns |
---|
Type | Description |
ByteString | The bytes for path.
|
getRequireMatchingFile()
public boolean getRequireMatchingFile()
Whether this handler should match the request if the file
referenced by the handler does not exist.
bool require_matching_file = 6;
Returns |
---|
Type | Description |
boolean | The requireMatchingFile.
|
getSerializedSize()
public int getSerializedSize()
Returns |
---|
Type | Description |
int | |
Overrides
getUnknownFields()
public final UnknownFieldSet getUnknownFields()
Overrides
getUploadPathRegex()
public String getUploadPathRegex()
Regular expression that matches the file paths for all files that should be
referenced by this handler.
string upload_path_regex = 2;
Returns |
---|
Type | Description |
String | The uploadPathRegex.
|
getUploadPathRegexBytes()
public ByteString getUploadPathRegexBytes()
Regular expression that matches the file paths for all files that should be
referenced by this handler.
string upload_path_regex = 2;
Returns |
---|
Type | Description |
ByteString | The bytes for uploadPathRegex.
|
hasExpiration()
public boolean hasExpiration()
Time a static file served by this handler should be cached
by web proxies and browsers.
.google.protobuf.Duration expiration = 5;
Returns |
---|
Type | Description |
boolean | Whether the expiration field is set.
|
hashCode()
Returns |
---|
Type | Description |
int | |
Overrides
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Overrides
internalGetMapField(int number)
protected MapField internalGetMapField(int number)
Parameter |
---|
Name | Description |
number | int
|
Overrides
isInitialized()
public final boolean isInitialized()
Overrides
newBuilderForType()
public StaticFilesHandler.Builder newBuilderForType()
newBuilderForType(GeneratedMessageV3.BuilderParent parent)
protected StaticFilesHandler.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Overrides
newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Overrides
toBuilder()
public StaticFilesHandler.Builder toBuilder()
writeTo(CodedOutputStream output)
public void writeTo(CodedOutputStream output)
Overrides