Done warp sea and fixed warp core
This commit is contained in:
parent
5dc311c93e
commit
569fc724c5
|
@ -5,13 +5,13 @@ import love.distributedrebirth.bassboonyd.BãßBȍőnAuthorInfoʸᴰ;
|
|||
@BãßBȍőnAuthorInfoʸᴰ(name = "willemtsade", copyright = "©Δ∞ 仙上主天")
|
||||
public class WaterOcean {
|
||||
|
||||
private WaterSea sea;
|
||||
private WaterSea water;
|
||||
|
||||
public WaterSea theSea() {
|
||||
return sea;
|
||||
public WaterSea theWater() {
|
||||
return water;
|
||||
}
|
||||
|
||||
public void setSea(WaterSea sea) {
|
||||
this.sea = sea;
|
||||
public void fillWater(WaterSea water) {
|
||||
this.water = water;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -8,7 +8,7 @@ import love.distributedrebirth.bassboonyd.BãßBȍőnAuthorInfoʸᴰ;
|
|||
@BãßBȍőnAuthorInfoʸᴰ(name = "willemtsade", copyright = "©Δ∞ 仙上主天")
|
||||
public class WaterOceanDriver extends X4ODriver<WaterOcean> {
|
||||
|
||||
static final public String LANGUAGE_NAME = "warp-ocean";
|
||||
static final public String LANGUAGE_NAME = "warp-sea";
|
||||
static final public String[] LANGUAGE_VERSIONS = new String[]{X4ODriver.DEFAULT_LANGUAGE_VERSION};
|
||||
|
||||
@Override
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
package love.distributedrebirth.warpme.sea;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import love.distributedrebirth.bassboonyd.BãßBȍőnAuthorInfoʸᴰ;
|
||||
|
@ -8,8 +9,8 @@ import love.distributedrebirth.bassboonyd.BãßBȍőnAuthorInfoʸᴰ;
|
|||
public class WaterSea {
|
||||
|
||||
private String name;
|
||||
private List<WaterSeaChain> seaChains;
|
||||
private List<WaterSeaMagic> seaMagics;
|
||||
private List<WaterSeaChain> seaChains = new ArrayList<>();
|
||||
private List<WaterSeaMagic> seaMagics = new ArrayList<>();
|
||||
|
||||
public String getName() {
|
||||
return name;
|
||||
|
|
|
@ -5,19 +5,19 @@ import love.distributedrebirth.bassboonyd.BãßBȍőnAuthorInfoʸᴰ;
|
|||
@BãßBȍőnAuthorInfoʸᴰ(name = "willemtsade", copyright = "©Δ∞ 仙上主天")
|
||||
public class WaterSeaChain {
|
||||
|
||||
private String path;
|
||||
private String key;
|
||||
private String tag;
|
||||
|
||||
public WaterSeaChain() {
|
||||
}
|
||||
|
||||
public String getPath() {
|
||||
return path;
|
||||
public WaterSeaChain(String key) {
|
||||
setKey(key);
|
||||
}
|
||||
|
||||
public void setPath(String path) {
|
||||
this.path = path;
|
||||
public WaterSeaChain(String key, String tag) {
|
||||
setKey(key);
|
||||
setTag(tag);
|
||||
}
|
||||
|
||||
public String getKey() {
|
||||
|
|
|
@ -1,34 +1,34 @@
|
|||
package love.distributedrebirth.warpme.sea;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import love.distributedrebirth.bassboonyd.BãßBȍőnAuthorInfoʸᴰ;
|
||||
|
||||
@BãßBȍőnAuthorInfoʸᴰ(name = "willemtsade", copyright = "©Δ∞ 仙上主天")
|
||||
public class WaterSeaMagic {
|
||||
|
||||
private String magicMime;
|
||||
private List<WaterSeaMagicResource> resources;
|
||||
private String mime;
|
||||
private String file;
|
||||
|
||||
public String getMagicMime() {
|
||||
return magicMime;
|
||||
public WaterSeaMagic() {
|
||||
}
|
||||
|
||||
public void setMagicMime(String magicMime) {
|
||||
this.magicMime = magicMime;
|
||||
public WaterSeaMagic(String mime, String file) {
|
||||
setMime(mime);
|
||||
setFile(file);
|
||||
}
|
||||
|
||||
public List<WaterSeaMagicResource> getResources() {
|
||||
return resources;
|
||||
public String getMime() {
|
||||
return mime;
|
||||
}
|
||||
|
||||
public void setResources(List<WaterSeaMagicResource> resources) {
|
||||
for (WaterSeaMagicResource resource: resources) {
|
||||
addResource(resource);
|
||||
}
|
||||
public void setMime(String mime) {
|
||||
this.mime = mime;
|
||||
}
|
||||
|
||||
public void addResource(WaterSeaMagicResource resource) {
|
||||
resources.add(resource);
|
||||
public String getFile() {
|
||||
return file;
|
||||
}
|
||||
|
||||
public void setFile(String file) {
|
||||
this.file = file;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,17 +0,0 @@
|
|||
package love.distributedrebirth.warpme.sea;
|
||||
|
||||
import love.distributedrebirth.bassboonyd.BãßBȍőnAuthorInfoʸᴰ;
|
||||
|
||||
@BãßBȍőnAuthorInfoʸᴰ(name = "willemtsade", copyright = "©Δ∞ 仙上主天")
|
||||
public class WaterSeaMagicResource {
|
||||
|
||||
private String file;
|
||||
|
||||
public String getFile() {
|
||||
return file;
|
||||
}
|
||||
|
||||
public void setFile(String file) {
|
||||
this.file = file;
|
||||
}
|
||||
}
|
|
@ -8,16 +8,16 @@
|
|||
id="warp-core-module">
|
||||
|
||||
<eld:classBindingHandler id="Bucket-Water"
|
||||
parentClass="love.distributedrebirth.numberxd.base2t.part.warp.WaterBucket"
|
||||
childClass="love.distributedrebirth.numberxd.base2t.part.warp.WaterCipher"
|
||||
parentClass="love.distributedrebirth.warpme.core.WaterBucket"
|
||||
childClass="love.distributedrebirth.warpme.core.WaterCipher"
|
||||
addMethod="fillWater" getMethod="theWater" />
|
||||
<eld:classBindingHandler id="Water-Heart"
|
||||
parentClass="love.distributedrebirth.numberxd.base2t.part.warp.WaterCipher"
|
||||
childClass="love.distributedrebirth.numberxd.base2t.part.warp.WaterCipherHeart"
|
||||
parentClass="love.distributedrebirth.warpme.core.WaterCipher"
|
||||
childClass="love.distributedrebirth.warpme.core.WaterCipherHeart"
|
||||
addMethod="addCipherHeart" getMethod="getCipherHearts" />
|
||||
<eld:classBindingHandler id="Heart-Tone"
|
||||
parentClass="love.distributedrebirth.numberxd.base2t.part.warp.WaterCipherHeart"
|
||||
childClass="love.distributedrebirth.numberxd.base2t.part.warp.WaterCipherHeartTone"
|
||||
parentClass="love.distributedrebirth.warpme.core.WaterCipherHeart"
|
||||
childClass="love.distributedrebirth.warpme.core.WaterCipherHeartTone"
|
||||
addMethod="addHeartTone" getMethod="getHeartTones" />
|
||||
|
||||
<eld:namespace
|
||||
|
@ -27,7 +27,7 @@
|
|||
description="Root namespace to have nice namespaceing."
|
||||
name="WarpCore Root Namespace" languageRoot="true" id="root">
|
||||
<eld:element tag="bucket"
|
||||
objectClass="love.distributedrebirth.numberxd.base2t.part.warp.WaterBucket"/>
|
||||
objectClass="love.distributedrebirth.warpme.core.WaterBucket"/>
|
||||
</eld:namespace>
|
||||
|
||||
<eld:namespace
|
||||
|
@ -37,10 +37,10 @@
|
|||
description="Language namespace to store warp cipher"
|
||||
name="WarpCore Language Namespace" id="cipher">
|
||||
<eld:element tag="water"
|
||||
objectClass="love.distributedrebirth.numberxd.base2t.part.warp.WaterCipher" />
|
||||
objectClass="love.distributedrebirth.warpme.core.WaterCipher" />
|
||||
<eld:element tag="heart"
|
||||
objectClass="love.distributedrebirth.numberxd.base2t.part.warp.WaterCipherHeart" />
|
||||
objectClass="love.distributedrebirth.warpme.core.WaterCipherHeart" />
|
||||
<eld:element tag="tone"
|
||||
objectClass="love.distributedrebirth.numberxd.base2t.part.warp.WaterCipherHeartTone" />
|
||||
objectClass="love.distributedrebirth.warpme.core.WaterCipherHeartTone" />
|
||||
</eld:namespace>
|
||||
</root:module>
|
46
lib-warpme/src/resources/META-INF/warp-sea/warp-sea-lang.eld
Normal file
46
lib-warpme/src/resources/META-INF/warp-sea/warp-sea-lang.eld
Normal file
|
@ -0,0 +1,46 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<root:module xmlns:root="http://eld.x4o.org/xml/ns/eld-root"
|
||||
xmlns:eld="http://eld.x4o.org/xml/ns/eld-lang"
|
||||
xmlns:conv="http://eld.x4o.org/xml/ns/eld-conv"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://eld.x4o.org/xml/ns/eld-root http://eld.x4o.org/xml/ns/eld-root-1.0.xsd"
|
||||
providerHost="warp-sea.x4o.distributedrebirth.love" providerName="WarpSeaᵐᵉ"
|
||||
id="warp-sea-module">
|
||||
|
||||
<eld:classBindingHandler id="WaterOcean-WaterSea"
|
||||
parentClass="love.distributedrebirth.warpme.sea.WaterOcean"
|
||||
childClass="love.distributedrebirth.warpme.sea.WaterSea"
|
||||
addMethod="fillWater" getMethod="theWater" />
|
||||
<eld:classBindingHandler id="WaterSea-WaterSeaChain"
|
||||
parentClass="love.distributedrebirth.warpme.sea.WaterSea"
|
||||
childClass="love.distributedrebirth.warpme.sea.WaterSeaChain"
|
||||
addMethod="addSeaChain" getMethod="getSeaChains" />
|
||||
<eld:classBindingHandler id="WaterSea-Tone"
|
||||
parentClass="love.distributedrebirth.warpme.sea.WaterSea"
|
||||
childClass="love.distributedrebirth.warpme.sea.WaterSeaMagic"
|
||||
addMethod="addSeaMagic" getMethod="getSeaMagics" />
|
||||
|
||||
<eld:namespace
|
||||
uri="http://wrap-sea.x4o.distributedrebirth.love/xml/ns/warp-sea-root"
|
||||
schemaUri="http://warp-sea.x4o.distributedrebirth.love/xml/ns/warp-sea-root-1.0.xsd"
|
||||
schemaResource="warp-sea-root-1.0.xsd" schemaPrefix="root"
|
||||
description="Root namespace to have nice namespaceing."
|
||||
name="WarpSea Root Namespace" languageRoot="true" id="root">
|
||||
<eld:element tag="ocean"
|
||||
objectClass="love.distributedrebirth.warpme.sea.WaterOcean"/>
|
||||
</eld:namespace>
|
||||
|
||||
<eld:namespace
|
||||
uri="http://warp-sea.x4o.distributedrebirth.love/xml/ns/warp-sea-link"
|
||||
schemaUri="http://warp-sea.x4o.distributedrebirth.love/xml/ns/warp-sea-link-1.0.xsd"
|
||||
schemaResource="warp-sea-link-1.0.xsd" schemaPrefix="link"
|
||||
description="Language namespace to store warp sea"
|
||||
name="WarpSea Language Namespace" id="link">
|
||||
<eld:element tag="sea"
|
||||
objectClass="love.distributedrebirth.warpme.sea.WaterSea" />
|
||||
<eld:element tag="chain"
|
||||
objectClass="love.distributedrebirth.warpme.sea.WaterSeaChain" />
|
||||
<eld:element tag="magic"
|
||||
objectClass="love.distributedrebirth.warpme.sea.WaterSeaMagic" />
|
||||
</eld:namespace>
|
||||
</root:module>
|
|
@ -0,0 +1,10 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<modules version="1.0"
|
||||
xmlns="http://language.x4o.org/xml/ns/modules"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://language.x4o.org/xml/ns/modules http://language.x4o.org/xml/ns/modules-1.0.xsd"
|
||||
>
|
||||
<language version="1.0">
|
||||
<eld-resource>warp-sea-lang.eld</eld-resource>
|
||||
</language>
|
||||
</modules>
|
|
@ -0,0 +1,39 @@
|
|||
package love.distributedrebirth.warpme.core;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
import org.junit.jupiter.api.Assertions;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.x4o.xml.io.X4OConnectionException;
|
||||
import org.xml.sax.SAXException;
|
||||
|
||||
import love.distributedrebirth.bassboonyd.BãßBȍőnAuthorInfoʸᴰ;
|
||||
|
||||
@BãßBȍőnAuthorInfoʸᴰ(name = "willemtsade", copyright = "©Δ∞ 仙上主天")
|
||||
public class WaterBucketDriverTest {
|
||||
|
||||
|
||||
@Test
|
||||
public void testWaterOcean() throws X4OConnectionException, SAXException, IOException {
|
||||
|
||||
WaterBucket bucket = new WaterBucket();
|
||||
WaterCipher cipher = new WaterCipher();
|
||||
|
||||
bucket.fillWater(cipher);
|
||||
cipher.setName("name");
|
||||
|
||||
WaterCipherHeartTone tone = new WaterCipherHeartTone();
|
||||
tone.setChinaKey("cn");
|
||||
tone.setDialTone("T1");
|
||||
tone.setPart("PART_0");
|
||||
tone.setChinaValue("china");
|
||||
|
||||
WaterCipherHeart heart = new WaterCipherHeart();
|
||||
heart.setBass(12345);
|
||||
heart.addHeartTone(tone);
|
||||
cipher.addCipherHeart(heart);
|
||||
|
||||
Assertions.assertNotNull(bucket);
|
||||
WaterBucketDriver.newInstance().createWriter().writeFile(bucket, new java.io.File("build/out-core.xml"));
|
||||
}
|
||||
}
|
|
@ -21,6 +21,6 @@ public class WaterShotDriverTest {
|
|||
drugs.addSoftHash(new WaterSoftHash("test2.txt", "ASDFYYF234234SDFSDFASDFS"));
|
||||
|
||||
Assertions.assertNotNull(drugs);
|
||||
WaterShotDriver.newInstance().createWriter().writeFile(drugs, new java.io.File("build/output.xml"));
|
||||
WaterShotDriver.newInstance().createWriter().writeFile(drugs, new java.io.File("build/out-hash.xml"));
|
||||
}
|
||||
}
|
|
@ -0,0 +1,32 @@
|
|||
package love.distributedrebirth.warpme.sea;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
import org.junit.jupiter.api.Assertions;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.x4o.xml.io.X4OConnectionException;
|
||||
import org.xml.sax.SAXException;
|
||||
|
||||
import love.distributedrebirth.bassboonyd.BãßBȍőnAuthorInfoʸᴰ;
|
||||
|
||||
@BãßBȍőnAuthorInfoʸᴰ(name = "willemtsade", copyright = "©Δ∞ 仙上主天")
|
||||
public class WaterOceanDriverTest {
|
||||
|
||||
@Test
|
||||
public void testWaterOcean() throws X4OConnectionException, SAXException, IOException {
|
||||
WaterOcean ocean = new WaterOcean();
|
||||
WaterSea sea = new WaterSea();
|
||||
sea.setName("MyFirstSea");
|
||||
|
||||
ocean.fillWater(sea);
|
||||
|
||||
sea.addSeaChain(new WaterSeaChain("2891738927138923"));
|
||||
sea.addSeaChain(new WaterSeaChain("2389473875891293"));
|
||||
|
||||
sea.addSeaMagic(new WaterSeaMagic("audio/mpegurl", "album/test.m3u"));
|
||||
sea.addSeaMagic(new WaterSeaMagic("inode/directory", "album/"));
|
||||
|
||||
Assertions.assertNotNull(ocean);
|
||||
WaterOceanDriver.newInstance().createWriter().writeFile(ocean, new java.io.File("build/out-sea.xml"));
|
||||
}
|
||||
}
|
Loading…
Reference in a new issue