mirror of
https://github.com/esiur/esiur-js.git
synced 2025-06-26 23:03:13 +00:00
Esiur 1.2.3
This commit is contained in:
@ -1,10 +0,0 @@
|
||||
<html>
|
||||
<head>
|
||||
<!--<script src="../build/esiur-debug.js"></script>-->
|
||||
<script src='test.js' type="module"></script>
|
||||
</head>
|
||||
|
||||
<body onload="">
|
||||
|
||||
</body>
|
||||
</html>
|
@ -1,59 +0,0 @@
|
||||
<html>
|
||||
<head>
|
||||
<script src="../src/IEventHandler.js"></script>
|
||||
<script src="../src/IDestructible.js"></script>
|
||||
<script src="../src/AutoList.js"></script>
|
||||
<script src="../src/KeyList.js"></script>
|
||||
<script src="../src/PropertyValue.js"></script>
|
||||
|
||||
<script src="../src/IResource.js"></script>
|
||||
<script src="../src/IStore.js"></script>
|
||||
<script src="../src/Structure.js"></script>
|
||||
|
||||
<script src="../src/StructureArray.js"></script>
|
||||
<script src="../src/ResourceArray.js"></script>
|
||||
|
||||
<script src="../src/MemberTemplate.js"></script>
|
||||
<script src="../src/AsyncReply.js"></script>
|
||||
<script src="../src/AsyncException.js"></script>
|
||||
|
||||
<script src="../src/Authentication.js"></script>
|
||||
<script src="../src/Session.js"></script>
|
||||
<script src="../src/IPermissionsManager.js"></script>
|
||||
|
||||
<script src="../src/AsyncBag.js"></script>
|
||||
<script src="../src/AsyncQueue.js"></script>
|
||||
<script src="../src/BinaryList.js"></script>
|
||||
<script src="../src/Codec.js"></script>
|
||||
<script src="../src/DataConverter.js"></script>
|
||||
<script src="../src/SHA256.js"></script>
|
||||
|
||||
<script src="../src/DataType.js"></script>
|
||||
<script src="../src/DistributedConnection.js"></script>
|
||||
<script src="../src/DistributedResource.js"></script>
|
||||
<script src="../src/DistributedResourceQueueItem.js"></script>
|
||||
<script src="../src/EventTemplate.js"></script>
|
||||
<script src="../src/FunctionTemplate.js"></script>
|
||||
<script src="../src/Guid.js"></script>
|
||||
<script src="../src/IIPAuthPacket.js"></script>
|
||||
<script src="../src/IIPPacket.js"></script>
|
||||
<script src="../src/Instance.js"></script>
|
||||
<script src="../src/NetworkBuffer.js"></script>
|
||||
<script src="../src/NotModified.js"></script>
|
||||
<script src="../src/PropertyTemplate.js"></script>
|
||||
|
||||
<script src="../src/ResourceTemplate.js"></script>
|
||||
<script src="../src/SendList.js"></script>
|
||||
<script src="../src/Warehouse.js"></script>
|
||||
<script src="../src/MemoryStore.js"></script>
|
||||
|
||||
<script src="app.js"></script>
|
||||
<script>
|
||||
|
||||
</script>
|
||||
</head>
|
||||
|
||||
<body onload="init()">
|
||||
|
||||
</body>
|
||||
</html>
|
@ -1,37 +1,8 @@
|
||||
<html>
|
||||
<head>
|
||||
<script src="../build/esiur.js"></script>
|
||||
<script>
|
||||
var demo;
|
||||
|
||||
class MyStore extends IStore
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
function init() {
|
||||
|
||||
var con = new DistributedConnection("ws://localhost:5001/iip/system/iip", "localhost", "demo", "1234");
|
||||
Warehouse.put(con, "remote");
|
||||
|
||||
con.on("ready", function (d) {
|
||||
con.get("db/my").then(function(rt){
|
||||
console.log("Object received.");
|
||||
demo = rt;
|
||||
rt.on("LevelUp", function(v){
|
||||
console.log("LevelUp", v);
|
||||
});
|
||||
|
||||
rt.Add(3);
|
||||
});
|
||||
}).on("error", function(sender, code, msg){
|
||||
console.log(sender, code, msg);
|
||||
});
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
|
||||
<body onload="init()">
|
||||
|
||||
</body>
|
||||
</html>
|
||||
|
||||
<head>
|
||||
<script src='test.js' type="module"></script>
|
||||
</head>
|
||||
|
||||
</body>
|
||||
</html>
|
39
test/test.js
39
test/test.js
@ -1,41 +1,18 @@
|
||||
var demo;
|
||||
|
||||
import IStore from '../src/Resource/IStore.js';
|
||||
import wh from '../src/Resource/Warehouse.js';
|
||||
import wh from '../src/esiur.js';
|
||||
|
||||
class MyStore extends IStore
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
wh.get("iip://localhost:5001/db/my", {username: "demo", password: "1234"})
|
||||
.then(x=>{
|
||||
console.log("connected", x);
|
||||
|
||||
|
||||
wh.get("iip://localhost:5001/db/my").then(x=>{
|
||||
console.log("connected", x);
|
||||
}).error(x=>{
|
||||
console.log("error", x);
|
||||
});
|
||||
|
||||
/*
|
||||
var con = new DistributedConnection("ws://localhost:5001/iip/system/iip", "localhost", "demo", "1234");
|
||||
Warehouse.put(con, "remote");
|
||||
|
||||
con.on("ready", function (d) {
|
||||
con.get("db/my").then(function(rt){
|
||||
console.log("Object received.");
|
||||
demo = rt;
|
||||
rt.on("LevelUp", function(a, b, c){
|
||||
console.log("LevelUp", a, b, c);
|
||||
});
|
||||
|
||||
rt.Add(3);
|
||||
|
||||
rt.Divide({nominator: 10, denominator: 50}).then(x=>{
|
||||
console.log(x);
|
||||
});
|
||||
|
||||
});
|
||||
}).on("error", function(sender, code, msg){
|
||||
console.log(sender, code, msg);
|
||||
});
|
||||
*/
|
||||
window.x = x;
|
||||
}).catch(x=>{
|
||||
console.log("error", x);
|
||||
});
|
Reference in New Issue
Block a user