public final class StaticFilesHandler extends com.google.protobuf.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| Modifier and Type | Class and Description |
|---|---|
static class |
StaticFilesHandler.Builder
Files served directly to the user for a given URL, such as images, CSS
stylesheets, or JavaScript source files.
|
com.google.protobuf.GeneratedMessageV3.BuilderParent, com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageType extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage,BuilderType extends com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageType,BuilderType>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageType extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage>, com.google.protobuf.GeneratedMessageV3.ExtendableMessageOrBuilder<MessageType extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage>, com.google.protobuf.GeneratedMessageV3.FieldAccessorTable| Modifier and Type | Field and Description |
|---|---|
static int |
APPLICATION_READABLE_FIELD_NUMBER |
static int |
EXPIRATION_FIELD_NUMBER |
static int |
HTTP_HEADERS_FIELD_NUMBER |
static int |
MIME_TYPE_FIELD_NUMBER |
static int |
PATH_FIELD_NUMBER |
static int |
REQUIRE_MATCHING_FILE_FIELD_NUMBER |
static int |
UPLOAD_PATH_REGEX_FIELD_NUMBER |
| Modifier and Type | Method and Description |
|---|---|
boolean |
containsHttpHeaders(java.lang.String key)
HTTP headers to use for all responses from these URLs.
|
boolean |
equals(java.lang.Object obj) |
boolean |
getApplicationReadable()
Whether files should also be uploaded as code data.
|
static StaticFilesHandler |
getDefaultInstance() |
StaticFilesHandler |
getDefaultInstanceForType() |
static com.google.protobuf.Descriptors.Descriptor |
getDescriptor() |
com.google.protobuf.Duration |
getExpiration()
Time a static file served by this handler should be cached
by web proxies and browsers.
|
com.google.protobuf.DurationOrBuilder |
getExpirationOrBuilder()
Time a static file served by this handler should be cached
by web proxies and browsers.
|
java.util.Map<java.lang.String,java.lang.String> |
getHttpHeaders()
Deprecated.
|
int |
getHttpHeadersCount()
HTTP headers to use for all responses from these URLs.
|
java.util.Map<java.lang.String,java.lang.String> |
getHttpHeadersMap()
HTTP headers to use for all responses from these URLs.
|
java.lang.String |
getHttpHeadersOrDefault(java.lang.String key,
java.lang.String defaultValue)
HTTP headers to use for all responses from these URLs.
|
java.lang.String |
getHttpHeadersOrThrow(java.lang.String key)
HTTP headers to use for all responses from these URLs.
|
java.lang.String |
getMimeType()
MIME type used to serve all files served by this handler.
|
com.google.protobuf.ByteString |
getMimeTypeBytes()
MIME type used to serve all files served by this handler.
|
com.google.protobuf.Parser<StaticFilesHandler> |
getParserForType() |
java.lang.String |
getPath()
Path to the static files matched by the URL pattern, from the
application root directory.
|
com.google.protobuf.ByteString |
getPathBytes()
Path to the static files matched by the URL pattern, from the
application root directory.
|
boolean |
getRequireMatchingFile()
Whether this handler should match the request if the file
referenced by the handler does not exist.
|
int |
getSerializedSize() |
com.google.protobuf.UnknownFieldSet |
getUnknownFields() |
java.lang.String |
getUploadPathRegex()
Regular expression that matches the file paths for all files that should be
referenced by this handler.
|
com.google.protobuf.ByteString |
getUploadPathRegexBytes()
Regular expression that matches the file paths for all files that should be
referenced by this handler.
|
boolean |
hasExpiration()
Time a static file served by this handler should be cached
by web proxies and browsers.
|
int |
hashCode() |
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable |
internalGetFieldAccessorTable() |
protected com.google.protobuf.MapField |
internalGetMapField(int number) |
boolean |
isInitialized() |
static StaticFilesHandler.Builder |
newBuilder() |
static StaticFilesHandler.Builder |
newBuilder(StaticFilesHandler prototype) |
StaticFilesHandler.Builder |
newBuilderForType() |
protected StaticFilesHandler.Builder |
newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) |
static StaticFilesHandler |
parseDelimitedFrom(java.io.InputStream input) |
static StaticFilesHandler |
parseDelimitedFrom(java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static StaticFilesHandler |
parseFrom(byte[] data) |
static StaticFilesHandler |
parseFrom(byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static StaticFilesHandler |
parseFrom(com.google.protobuf.ByteString data) |
static StaticFilesHandler |
parseFrom(com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static StaticFilesHandler |
parseFrom(com.google.protobuf.CodedInputStream input) |
static StaticFilesHandler |
parseFrom(com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static StaticFilesHandler |
parseFrom(java.io.InputStream input) |
static StaticFilesHandler |
parseFrom(java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
static com.google.protobuf.Parser<StaticFilesHandler> |
parser() |
StaticFilesHandler.Builder |
toBuilder() |
void |
writeTo(com.google.protobuf.CodedOutputStream output) |
computeStringSize, computeStringSizeNoTag, getAllFields, getDescriptorForType, getField, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, hasField, hasOneof, makeExtensionsImmutable, newBuilderForType, parseDelimitedWithIOException, parseDelimitedWithIOException, parseUnknownField, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTagfindInitializationErrors, getInitializationErrorString, hashBoolean, hashEnum, hashEnumList, hashFields, hashLong, toStringaddAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeToclone, finalize, getClass, notify, notifyAll, wait, wait, waitpublic static final int PATH_FIELD_NUMBER
public static final int UPLOAD_PATH_REGEX_FIELD_NUMBER
public static final int HTTP_HEADERS_FIELD_NUMBER
public static final int MIME_TYPE_FIELD_NUMBER
public static final int EXPIRATION_FIELD_NUMBER
public static final int REQUIRE_MATCHING_FILE_FIELD_NUMBER
public static final int APPLICATION_READABLE_FIELD_NUMBER
public final com.google.protobuf.UnknownFieldSet getUnknownFields()
getUnknownFields in interface com.google.protobuf.MessageOrBuildergetUnknownFields in class com.google.protobuf.GeneratedMessageV3public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
protected com.google.protobuf.MapField internalGetMapField(int number)
internalGetMapField in class com.google.protobuf.GeneratedMessageV3protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3public java.lang.String 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.
optional string path = 1;getPath in interface StaticFilesHandlerOrBuilderpublic com.google.protobuf.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.
optional string path = 1;getPathBytes in interface StaticFilesHandlerOrBuilderpublic java.lang.String getUploadPathRegex()
Regular expression that matches the file paths for all files that should be referenced by this handler.
optional string upload_path_regex = 2;getUploadPathRegex in interface StaticFilesHandlerOrBuilderpublic com.google.protobuf.ByteString getUploadPathRegexBytes()
Regular expression that matches the file paths for all files that should be referenced by this handler.
optional string upload_path_regex = 2;getUploadPathRegexBytes in interface StaticFilesHandlerOrBuilderpublic int getHttpHeadersCount()
StaticFilesHandlerOrBuilderHTTP headers to use for all responses from these URLs.
map<string, string> http_headers = 3;getHttpHeadersCount in interface StaticFilesHandlerOrBuilderpublic boolean containsHttpHeaders(java.lang.String key)
HTTP headers to use for all responses from these URLs.
map<string, string> http_headers = 3;containsHttpHeaders in interface StaticFilesHandlerOrBuilder@Deprecated public java.util.Map<java.lang.String,java.lang.String> getHttpHeaders()
getHttpHeadersMap() instead.getHttpHeaders in interface StaticFilesHandlerOrBuilderpublic java.util.Map<java.lang.String,java.lang.String> getHttpHeadersMap()
HTTP headers to use for all responses from these URLs.
map<string, string> http_headers = 3;getHttpHeadersMap in interface StaticFilesHandlerOrBuilderpublic java.lang.String getHttpHeadersOrDefault(java.lang.String key,
java.lang.String defaultValue)
HTTP headers to use for all responses from these URLs.
map<string, string> http_headers = 3;getHttpHeadersOrDefault in interface StaticFilesHandlerOrBuilderpublic java.lang.String getHttpHeadersOrThrow(java.lang.String key)
HTTP headers to use for all responses from these URLs.
map<string, string> http_headers = 3;getHttpHeadersOrThrow in interface StaticFilesHandlerOrBuilderpublic java.lang.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.
optional string mime_type = 4;getMimeType in interface StaticFilesHandlerOrBuilderpublic com.google.protobuf.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.
optional string mime_type = 4;getMimeTypeBytes in interface StaticFilesHandlerOrBuilderpublic boolean hasExpiration()
Time a static file served by this handler should be cached by web proxies and browsers.
optional .google.protobuf.Duration expiration = 5;hasExpiration in interface StaticFilesHandlerOrBuilderpublic com.google.protobuf.Duration getExpiration()
Time a static file served by this handler should be cached by web proxies and browsers.
optional .google.protobuf.Duration expiration = 5;getExpiration in interface StaticFilesHandlerOrBuilderpublic com.google.protobuf.DurationOrBuilder getExpirationOrBuilder()
Time a static file served by this handler should be cached by web proxies and browsers.
optional .google.protobuf.Duration expiration = 5;getExpirationOrBuilder in interface StaticFilesHandlerOrBuilderpublic boolean getRequireMatchingFile()
Whether this handler should match the request if the file referenced by the handler does not exist.
optional bool require_matching_file = 6;getRequireMatchingFile in interface StaticFilesHandlerOrBuilderpublic 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.
optional bool application_readable = 7;getApplicationReadable in interface StaticFilesHandlerOrBuilderpublic final boolean isInitialized()
isInitialized in interface com.google.protobuf.MessageLiteOrBuilderisInitialized in class com.google.protobuf.GeneratedMessageV3public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException
writeTo in interface com.google.protobuf.MessageLitewriteTo in class com.google.protobuf.GeneratedMessageV3java.io.IOExceptionpublic int getSerializedSize()
getSerializedSize in interface com.google.protobuf.MessageLitegetSerializedSize in class com.google.protobuf.GeneratedMessageV3public boolean equals(java.lang.Object obj)
equals in interface com.google.protobuf.Messageequals in class com.google.protobuf.AbstractMessagepublic int hashCode()
hashCode in interface com.google.protobuf.MessagehashCode in class com.google.protobuf.AbstractMessagepublic static StaticFilesHandler parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static StaticFilesHandler parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static StaticFilesHandler parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static StaticFilesHandler parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
com.google.protobuf.InvalidProtocolBufferExceptionpublic static StaticFilesHandler parseFrom(java.io.InputStream input) throws java.io.IOException
java.io.IOExceptionpublic static StaticFilesHandler parseFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException
java.io.IOExceptionpublic static StaticFilesHandler parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException
java.io.IOExceptionpublic static StaticFilesHandler parseDelimitedFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException
java.io.IOExceptionpublic static StaticFilesHandler parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException
java.io.IOExceptionpublic static StaticFilesHandler parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException
java.io.IOExceptionpublic StaticFilesHandler.Builder newBuilderForType()
newBuilderForType in interface com.google.protobuf.MessagenewBuilderForType in interface com.google.protobuf.MessageLitepublic static StaticFilesHandler.Builder newBuilder()
public static StaticFilesHandler.Builder newBuilder(StaticFilesHandler prototype)
public StaticFilesHandler.Builder toBuilder()
toBuilder in interface com.google.protobuf.MessagetoBuilder in interface com.google.protobuf.MessageLiteprotected StaticFilesHandler.Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
newBuilderForType in class com.google.protobuf.GeneratedMessageV3public static StaticFilesHandler getDefaultInstance()
public static com.google.protobuf.Parser<StaticFilesHandler> parser()
public com.google.protobuf.Parser<StaticFilesHandler> getParserForType()
getParserForType in interface com.google.protobuf.MessagegetParserForType in interface com.google.protobuf.MessageLitegetParserForType in class com.google.protobuf.GeneratedMessageV3public StaticFilesHandler getDefaultInstanceForType()
getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuildergetDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder