public final class DataURLs extends Object
| Modifier and Type | Class and Description |
|---|---|
static class |
DataURLs.Builder
A class that can be used to build data URLs.
|
| Modifier and Type | Method and Description |
|---|---|
static DataURLs.Builder.FromBytes |
builder(byte[] data)
Creates a new data URL builder.
|
static DataURLs.Builder.FromBytes |
builder(InputStream data)
Creates a new data URL builder.
|
static DataURLs.Builder.FromText |
builder(Reader data)
Creates a new data URL builder.
|
static DataURLs.Builder.FromText |
builder(String data)
Creates a new data URL builder.
|
static URL |
create(String spec)
Creates a new data URL for the given full URL string.
|
public static URL create(String spec) throws MalformedURLException
spec - The string to create a new data URL for.MalformedURLException - If the given URL string is invalid.public static DataURLs.Builder.FromText builder(String data)
data - The data for created data URLs.public static DataURLs.Builder.FromText builder(Reader data)
Note: the builder's DataURLs.Builder.build() method will fail with an UncheckedIOException if an I/O error occurs while
reading from the data stream.
data - The data for created data URLs.public static DataURLs.Builder.FromBytes builder(byte[] data)
data - The data for created data URLs.public static DataURLs.Builder.FromBytes builder(InputStream data)
Note: the builder's DataURLs.Builder.build() method will fail with an UncheckedIOException if an I/O error occurs while
reading from the data stream.
data - The data for created data URLs.Copyright © 2017–2023. All rights reserved.