UrlImageSource.java
1.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
/*
* Decompiled with CFR 0_118.
*
* Could not load the following classes:
* com.scene7.is.provider.ImageSource
* com.scene7.is.sleng.ImageAccessException
* com.scene7.is.sleng.Sleng
* org.jetbrains.annotations.NotNull
*/
package com.scene7.is.ps.provider;
import com.scene7.is.provider.ImageSource;
import com.scene7.is.sleng.ImageAccessException;
import com.scene7.is.sleng.Sleng;
import java.net.MalformedURLException;
import java.net.URL;
import org.jetbrains.annotations.NotNull;
public class UrlImageSource
implements ImageSource {
@NotNull
private final URL url;
private final boolean validation;
public UrlImageSource(@NotNull String source, boolean validation) throws MalformedURLException {
this.url = new URL(source);
this.validation = validation;
}
@NotNull
public String toString() {
return this.url.toString();
}
public void injectSleng(@NotNull Sleng sleng) throws ImageAccessException {
sleng.openURL(this.url, this.validation);
}
}