Added ShortenConfig && LookupConfig
This commit is contained in:
parent
63645f7cf4
commit
e20934fc08
15 changed files with 138 additions and 171 deletions
|
@ -1,9 +1,9 @@
|
|||
package com.example;
|
||||
|
||||
import net.thauvin.erik.isgd.Config;
|
||||
import net.thauvin.erik.isgd.Format;
|
||||
import net.thauvin.erik.isgd.Isgd;
|
||||
import net.thauvin.erik.isgd.IsgdException;
|
||||
import net.thauvin.erik.isgd.LookupConfig;
|
||||
|
||||
public final class IsgdSample {
|
||||
public static void main(final String[] args) {
|
||||
|
@ -12,7 +12,7 @@ public final class IsgdSample {
|
|||
try {
|
||||
if (arg.contains("is.gd")) {
|
||||
System.out.println(arg + " <-- " + Isgd.lookup(arg));
|
||||
System.out.print(Isgd.lookup(new Config.Builder().shortUrl(arg).format(Format.WEB).build()));
|
||||
System.out.print(Isgd.lookup(new LookupConfig.Builder(arg).format(Format.WEB).build()));
|
||||
} else {
|
||||
System.out.println(arg + " --> " + Isgd.shorten(arg));
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue