public static final class EmbeddedSass.OutboundMessage.FileImportRequest.Builder extends com.google.protobuf.GeneratedMessageV3.Builder<EmbeddedSass.OutboundMessage.FileImportRequest.Builder> implements EmbeddedSass.OutboundMessage.FileImportRequestOrBuilder
A request for a custom filesystem importer to load the contents of a
stylesheet.
A filesystem importer is represented in the compiler as an [importer]. When
the importer is invoked with a string `string`:
[importer]: https://github.com/sass/sass/tree/main/spec/modules.md#importer
* If `string` is an absolute URL whose scheme is `file`:
* Let `url` be string.
* Otherwise:
* Let `fromImport` be `true` if the importer is being run for an
`@import` and `false` otherwise.
* Let `response` be the result of sending a `FileImportRequest` with
`string` as its `url` and `fromImport` as `from_import`.
* If `response.result` is null, return null.
* Otherwise, if `response.result.error` is set, throw an error.
* Otherwise, let `url` be `response.result.file_url`.
* Let `resolved` be the result of [resolving `url`].
* If `resolved` is null, return null.
* Let `text` be the contents of the file at `resolved`.
* Let `syntax` be:
* "scss" if `url` ends in `.scss`.
* "indented" if `url` ends in `.sass`.
* "css" if `url` ends in `.css`.
> The algorithm for resolving a `file:` URL guarantees that `url` will have
> one of these extensions.
* Return `text`, `syntax`, and `resolved`.
[resolving `url`]: https://github.com/sass/sass/tree/main/spec/modules.md#resolving-a-file-url
Protobuf type sass.embedded_protocol.OutboundMessage.FileImportRequestaddRepeatedField, clearField, clearOneof, clone, getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, internalGetMapField, internalGetMutableMapField, isClean, markClean, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setField, setRepeatedField, setUnknownFieldSetBuilder, setUnknownFieldsProto3findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toStringaddAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, newUninitializedMessageExceptionequals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitfindInitializationErrors, getAllFields, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneofpublic static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3.Builder<EmbeddedSass.OutboundMessage.FileImportRequest.Builder>public EmbeddedSass.OutboundMessage.FileImportRequest.Builder clear()
clear in interface com.google.protobuf.Message.Builderclear in interface com.google.protobuf.MessageLite.Builderclear in class com.google.protobuf.GeneratedMessageV3.Builder<EmbeddedSass.OutboundMessage.FileImportRequest.Builder>public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
getDescriptorForType in interface com.google.protobuf.Message.BuildergetDescriptorForType in interface com.google.protobuf.MessageOrBuildergetDescriptorForType in class com.google.protobuf.GeneratedMessageV3.Builder<EmbeddedSass.OutboundMessage.FileImportRequest.Builder>public EmbeddedSass.OutboundMessage.FileImportRequest getDefaultInstanceForType()
getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuildergetDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilderpublic EmbeddedSass.OutboundMessage.FileImportRequest build()
build in interface com.google.protobuf.Message.Builderbuild in interface com.google.protobuf.MessageLite.Builderpublic EmbeddedSass.OutboundMessage.FileImportRequest buildPartial()
buildPartial in interface com.google.protobuf.Message.BuilderbuildPartial in interface com.google.protobuf.MessageLite.Builderpublic EmbeddedSass.OutboundMessage.FileImportRequest.Builder mergeFrom(com.google.protobuf.Message other)
mergeFrom in interface com.google.protobuf.Message.BuildermergeFrom in class com.google.protobuf.AbstractMessage.Builder<EmbeddedSass.OutboundMessage.FileImportRequest.Builder>public EmbeddedSass.OutboundMessage.FileImportRequest.Builder mergeFrom(EmbeddedSass.OutboundMessage.FileImportRequest other)
public final boolean isInitialized()
isInitialized in interface com.google.protobuf.MessageLiteOrBuilderisInitialized in class com.google.protobuf.GeneratedMessageV3.Builder<EmbeddedSass.OutboundMessage.FileImportRequest.Builder>public EmbeddedSass.OutboundMessage.FileImportRequest.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
mergeFrom in interface com.google.protobuf.Message.BuildermergeFrom in interface com.google.protobuf.MessageLite.BuildermergeFrom in class com.google.protobuf.AbstractMessage.Builder<EmbeddedSass.OutboundMessage.FileImportRequest.Builder>IOExceptionpublic int getId()
uint32 id = 1;getId in interface EmbeddedSass.OutboundMessage.FileImportRequestOrBuilderpublic EmbeddedSass.OutboundMessage.FileImportRequest.Builder setId(int value)
uint32 id = 1;value - The id to set.public EmbeddedSass.OutboundMessage.FileImportRequest.Builder clearId()
uint32 id = 1;public int getCompilationId()
The request id for the compilation that triggered the message. Mandatory.
uint32 compilation_id = 2;getCompilationId in interface EmbeddedSass.OutboundMessage.FileImportRequestOrBuilderpublic EmbeddedSass.OutboundMessage.FileImportRequest.Builder setCompilationId(int value)
The request id for the compilation that triggered the message. Mandatory.
uint32 compilation_id = 2;value - The compilationId to set.public EmbeddedSass.OutboundMessage.FileImportRequest.Builder clearCompilationId()
The request id for the compilation that triggered the message. Mandatory.
uint32 compilation_id = 2;public int getImporterId()
The unique ID of the importer being invoked. This must match an `Importer.file_importer_id` passed to this compilation in `CompileRequest.importers` or `CompileRequest.input.string.importer`. Mandatory.
uint32 importer_id = 3;getImporterId in interface EmbeddedSass.OutboundMessage.FileImportRequestOrBuilderpublic EmbeddedSass.OutboundMessage.FileImportRequest.Builder setImporterId(int value)
The unique ID of the importer being invoked. This must match an `Importer.file_importer_id` passed to this compilation in `CompileRequest.importers` or `CompileRequest.input.string.importer`. Mandatory.
uint32 importer_id = 3;value - The importerId to set.public EmbeddedSass.OutboundMessage.FileImportRequest.Builder clearImporterId()
The unique ID of the importer being invoked. This must match an `Importer.file_importer_id` passed to this compilation in `CompileRequest.importers` or `CompileRequest.input.string.importer`. Mandatory.
uint32 importer_id = 3;public String getUrl()
The (non-canonicalized) URL of the import.
string url = 4;getUrl in interface EmbeddedSass.OutboundMessage.FileImportRequestOrBuilderpublic com.google.protobuf.ByteString getUrlBytes()
The (non-canonicalized) URL of the import.
string url = 4;getUrlBytes in interface EmbeddedSass.OutboundMessage.FileImportRequestOrBuilderpublic EmbeddedSass.OutboundMessage.FileImportRequest.Builder setUrl(String value)
The (non-canonicalized) URL of the import.
string url = 4;value - The url to set.public EmbeddedSass.OutboundMessage.FileImportRequest.Builder clearUrl()
The (non-canonicalized) URL of the import.
string url = 4;public EmbeddedSass.OutboundMessage.FileImportRequest.Builder setUrlBytes(com.google.protobuf.ByteString value)
The (non-canonicalized) URL of the import.
string url = 4;value - The bytes for url to set.public boolean getFromImport()
/ Whether this request comes from an `@import` rule. / / When evaluating `@import` rules, filesystem importers should load an / [import-only file] if one exists for the URL being canonicalized. / Otherwise, canonicalization should be identical for `@import` and `@use` / rules. / / [import-only file]: https://sass-lang.com/documentation/at-rules/import#import-only-files
bool from_import = 5;getFromImport in interface EmbeddedSass.OutboundMessage.FileImportRequestOrBuilderpublic EmbeddedSass.OutboundMessage.FileImportRequest.Builder setFromImport(boolean value)
/ Whether this request comes from an `@import` rule. / / When evaluating `@import` rules, filesystem importers should load an / [import-only file] if one exists for the URL being canonicalized. / Otherwise, canonicalization should be identical for `@import` and `@use` / rules. / / [import-only file]: https://sass-lang.com/documentation/at-rules/import#import-only-files
bool from_import = 5;value - The fromImport to set.public EmbeddedSass.OutboundMessage.FileImportRequest.Builder clearFromImport()
/ Whether this request comes from an `@import` rule. / / When evaluating `@import` rules, filesystem importers should load an / [import-only file] if one exists for the URL being canonicalized. / Otherwise, canonicalization should be identical for `@import` and `@use` / rules. / / [import-only file]: https://sass-lang.com/documentation/at-rules/import#import-only-files
bool from_import = 5;public final EmbeddedSass.OutboundMessage.FileImportRequest.Builder setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
setUnknownFields in interface com.google.protobuf.Message.BuildersetUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<EmbeddedSass.OutboundMessage.FileImportRequest.Builder>public final EmbeddedSass.OutboundMessage.FileImportRequest.Builder mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
mergeUnknownFields in interface com.google.protobuf.Message.BuildermergeUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<EmbeddedSass.OutboundMessage.FileImportRequest.Builder>