|
4 | 4 | "description": "A Model and a NoSQL Database for Components", |
5 | 5 | "_id": "e89c617b6b15d24", |
6 | 6 | "schemas": { |
| 7 | + "MonocoSchema": { |
| 8 | + "systemLoaded": "event", |
| 9 | + "_id": "MonocoSchema", |
| 10 | + "_name": "MonocoSchema", |
| 11 | + "_inherit": [ |
| 12 | + "MonocoComponentSchema" |
| 13 | + ], |
| 14 | + "_core": true, |
| 15 | + "version": "property", |
| 16 | + "find": "method", |
| 17 | + "load": "method", |
| 18 | + "system": "method", |
| 19 | + "warning": "event", |
| 20 | + "ready": "event" |
| 21 | + }, |
7 | 22 | "Monoco": { |
| 23 | + "systemLoaded": {}, |
8 | 24 | "_id": "Monoco", |
9 | 25 | "_name": "Monoco", |
10 | 26 | "_schema": "MonocoSchema", |
|
464 | 480 | "type": "method", |
465 | 481 | "create": "method" |
466 | 482 | }, |
467 | | - "MonocoSchema": { |
468 | | - "_id": "MonocoSchema", |
469 | | - "_name": "MonocoSchema", |
470 | | - "_inherit": [ |
471 | | - "MonocoComponentSchema" |
472 | | - ], |
473 | | - "_core": true, |
474 | | - "version": "property", |
475 | | - "find": "method", |
476 | | - "load": "method", |
477 | | - "system": "method", |
478 | | - "warning": "event", |
479 | | - "ready": "event" |
480 | | - }, |
481 | 483 | "MonocoState": { |
482 | 484 | "_id": "MonocoState", |
483 | 485 | "_name": "MonocoState", |
|
734 | 736 | "_id": "1f6001773a18791", |
735 | 737 | "component": "monoco", |
736 | 738 | "state": "ready", |
737 | | - "action": "function ready() { var systems = [], system = null, i = 0, length = 0; if (typeof document !== 'undefined') { systems = document.querySelectorAll('link[rel=system]'); length = systems.length; for (i = 0; i < length; i++) { system = systems[i]; this.load(system.href, false); } } }", |
| 739 | + "action": "function ready() { var systems = [], system = null, i = 0, length = 0; if (typeof document !== 'undefined') { systems = document.querySelectorAll('link[rel=system]'); length = systems.length; for (i = 0; i < length; i++) { system = systems[i]; this.load(system.href, false); this.systemLoaded();} } }", |
738 | 740 | "core": true |
739 | 741 | }, |
740 | | - "1e9821b2a3125de": { |
741 | | - "_id": "1e9821b2a3125de", |
| 742 | + "1db2d1b4e619242": { |
| 743 | + "_id": "1db2d1b4e619242", |
742 | 744 | "component": "Monoco", |
743 | 745 | "state": "error", |
744 | 746 | "action": "function error(data) { console.error('monoco: ' + data.message, data.error); }", |
745 | 747 | "core": true |
746 | 748 | }, |
747 | | - "11ced1bb5c189ec": { |
748 | | - "_id": "11ced1bb5c189ec", |
| 749 | + "1eb721fcf912afe": { |
| 750 | + "_id": "1eb721fcf912afe", |
749 | 751 | "component": "Monoco", |
750 | 752 | "state": "find", |
751 | 753 | "action": "function find(Class, query) { return $component.find(Class, query);}", |
752 | 754 | "core": true, |
753 | 755 | "useCoreAPI": true |
754 | 756 | }, |
755 | | - "1eaa91ef7d1aaca": { |
756 | | - "_id": "1eaa91ef7d1aaca", |
| 757 | + "102c714a641ecaa": { |
| 758 | + "_id": "102c714a641ecaa", |
757 | 759 | "component": "Monoco", |
758 | 760 | "state": "system", |
759 | 761 | "action": "function system(name) { var System = null, system = {}, result = [], conf = {}; if (name) { conf.master = true; conf.name = name; System = this.require('MonocoSystem'); system = new System(conf); } else { result = this.find('MonocoSystem', {'master': true}); if (result.length) { system = result[0]; } } return system; }", |
760 | 762 | "core": true |
761 | 763 | }, |
762 | | - "1ff5011cee13f5e": { |
763 | | - "_id": "1ff5011cee13f5e", |
| 764 | + "1e7271a8c314756": { |
| 765 | + "_id": "1e7271a8c314756", |
764 | 766 | "component": "Monoco", |
765 | 767 | "state": "warning", |
766 | 768 | "action": "function warning(message) { console.warn('monoco: ' + message); }", |
767 | 769 | "core": true |
768 | 770 | }, |
769 | | - "11caf178fa134b9": { |
770 | | - "_id": "11caf178fa134b9", |
| 771 | + "110a41de0815dab": { |
| 772 | + "_id": "110a41de0815dab", |
771 | 773 | "component": "MonocoChannel", |
772 | 774 | "state": "listen", |
773 | 775 | "action": "function listen(event, action) { $channel.listen(event, action); }", |
774 | 776 | "core": true, |
775 | 777 | "useCoreAPI": true |
776 | 778 | }, |
777 | | - "16ad41550714670": { |
778 | | - "_id": "16ad41550714670", |
| 779 | + "128b312af1127aa": { |
| 780 | + "_id": "128b312af1127aa", |
779 | 781 | "component": "MonocoChannel", |
780 | 782 | "state": "send", |
781 | 783 | "action": "function send(message) { return $channel.send(message); }", |
782 | 784 | "core": true, |
783 | 785 | "useCoreAPI": true |
784 | 786 | }, |
785 | | - "1d82513ca81cfec": { |
786 | | - "_id": "1d82513ca81cfec", |
| 787 | + "1396313e9214352": { |
| 788 | + "_id": "1396313e9214352", |
787 | 789 | "component": "MonocoClassInfo", |
788 | 790 | "state": "event", |
789 | 791 | "action": "function event(name) { var result = {}; if (this.metamodel()[name] === 'event') { result = this.model()[name]; } return result; }", |
790 | 792 | "core": true |
791 | 793 | }, |
792 | | - "14d5511a2e1c2fe": { |
793 | | - "_id": "14d5511a2e1c2fe", |
| 794 | + "15184191c9112e3": { |
| 795 | + "_id": "15184191c9112e3", |
794 | 796 | "component": "MonocoClassInfo", |
795 | 797 | "state": "events", |
796 | 798 | "action": "function events() { var keys = Object.keys(this.metamodel()), item = '', result = [], i = 0, length = 0; length = keys.length; for (i = 0; i < length; i++) { item = keys[i]; if (this.metamodel()[item] === 'event') { result.push(item); } } return result; }", |
797 | 799 | "core": true |
798 | 800 | }, |
799 | | - "15b8a12ba813c2e": { |
800 | | - "_id": "15b8a12ba813c2e", |
| 801 | + "145a91494d13499": { |
| 802 | + "_id": "145a91494d13499", |
801 | 803 | "component": "MonocoClassInfo", |
802 | 804 | "state": "method", |
803 | 805 | "action": "function method(name) { var result = {}; if (this.metamodel()[name] === 'method') { result = this.model()[name]; } return result; }", |
804 | 806 | "core": true |
805 | 807 | }, |
806 | | - "19b9a1bc2119ae3": { |
807 | | - "_id": "19b9a1bc2119ae3", |
| 808 | + "171691267319632": { |
| 809 | + "_id": "171691267319632", |
808 | 810 | "component": "MonocoClassInfo", |
809 | 811 | "state": "methods", |
810 | 812 | "action": "function methods() { var keys = Object.keys(this.metamodel()), item = '', result = [], i = 0, length = 0; length = keys.length; for (i = 0; i < length; i++) { item = keys[i]; if (this.metamodel()[item] === 'method') { result.push(item); } } return result; }", |
811 | 813 | "core": true |
812 | 814 | }, |
813 | | - "1d9771924611328": { |
814 | | - "_id": "1d9771924611328", |
| 815 | + "1d1aa1c14a1fd7f": { |
| 816 | + "_id": "1d1aa1c14a1fd7f", |
815 | 817 | "component": "MonocoClassInfo", |
816 | 818 | "state": "properties", |
817 | 819 | "action": "function properties() { var keys = Object.keys(this.metamodel()), item = '', result = [], i = 0, length = 0; length = keys.length; for (i = 0; i < length; i++) { item = keys[i]; if (this.metamodel()[item] === 'property') { result.push(item); } } return result; }", |
818 | 820 | "core": true |
819 | 821 | }, |
820 | | - "182f1179a81d52a": { |
821 | | - "_id": "182f1179a81d52a", |
| 822 | + "17c03118d1180c5": { |
| 823 | + "_id": "17c03118d1180c5", |
822 | 824 | "component": "MonocoClassInfo", |
823 | 825 | "state": "property", |
824 | 826 | "action": "function property(name) { var result = {}; if (this.metamodel()[name] === 'property') { result = this.model()[name]; } return result; }", |
825 | 827 | "core": true |
826 | 828 | }, |
827 | | - "18cd51ab241fbe8": { |
828 | | - "_id": "18cd51ab241fbe8", |
| 829 | + "1749013e771cc97": { |
| 830 | + "_id": "1749013e771cc97", |
829 | 831 | "component": "MonocoComponent", |
830 | 832 | "state": "destroy", |
831 | 833 | "action": "function destroy() { $component.destroy(this.id()); }", |
832 | 834 | "core": true, |
833 | 835 | "useCoreAPI": true |
834 | 836 | }, |
835 | | - "1fa9f1557b1c67c": { |
836 | | - "_id": "1fa9f1557b1c67c", |
| 837 | + "177a11340c12de7": { |
| 838 | + "_id": "177a11340c12de7", |
837 | 839 | "component": "MonocoComponent", |
838 | 840 | "state": "off", |
839 | 841 | "action": "function off(state, behaviorId) { var args = [], i = 0, length = 0; length = arguments.length; for (i = 0; i < length - 7; i++) { args.push(arguments[i]); } if ($workflow.checkParams({\"component\": this, \"methodName\": \"off\", \"args\": args})) { if ($metamodel.isValidState(state, this.constructor.name)) {$behavior.remove({\"behaviorId\": behaviorId, \"componentId\": this.id(), \"state\": state}); } else { $helper.getMonoco().warning({ \"message\":\"invoke 'off' method of component '\" + this.id() + \"' with an invalid state '\" + state + \"'\"}); } } }", |
840 | 842 | "core": true, |
841 | 843 | "useCoreAPI": true |
842 | 844 | }, |
843 | | - "1b0d112d88129d5": { |
844 | | - "_id": "1b0d112d88129d5", |
| 845 | + "1840a1da96191a6": { |
| 846 | + "_id": "1840a1da96191a6", |
845 | 847 | "component": "MonocoComponent", |
846 | 848 | "state": "require", |
847 | 849 | "action": "function require(id) { return $component.get(id); }", |
848 | 850 | "core": true, |
849 | 851 | "useCoreAPI": true |
850 | 852 | }, |
851 | | - "1f96711cb01f43a": { |
852 | | - "_id": "1f96711cb01f43a", |
| 853 | + "176d81187419117": { |
| 854 | + "_id": "176d81187419117", |
853 | 855 | "component": "MonocoDatabase", |
854 | 856 | "state": "subsystem", |
855 | 857 | "action": "function subsystem(params) { return $db.subsystem(params); }", |
856 | 858 | "core": true, |
857 | 859 | "useCoreAPI": true |
858 | 860 | }, |
859 | | - "1a7f91f8711a8a6": { |
860 | | - "_id": "1a7f91f8711a8a6", |
| 861 | + "161881d4fc1b2ad": { |
| 862 | + "_id": "161881d4fc1b2ad", |
861 | 863 | "component": "MonocoDatabase", |
862 | 864 | "state": "system", |
863 | 865 | "action": "function system(system) { return $db.system(system); }", |
864 | 866 | "core": true, |
865 | 867 | "useCoreAPI": true |
866 | 868 | }, |
867 | | - "1362b1a251106cb": { |
868 | | - "_id": "1362b1a251106cb", |
| 869 | + "1e9ef11e601639a": { |
| 870 | + "_id": "1e9ef11e601639a", |
869 | 871 | "component": "MonocoMetamodel", |
870 | 872 | "state": "create", |
871 | 873 | "action": "function create() { $metamodel.create(); }", |
872 | 874 | "core": true, |
873 | 875 | "useCoreAPI": true |
874 | 876 | }, |
875 | | - "10d2d17af21b75e": { |
876 | | - "_id": "10d2d17af21b75e", |
| 877 | + "17bd2144571287d": { |
| 878 | + "_id": "17bd2144571287d", |
877 | 879 | "component": "MonocoMetamodel", |
878 | 880 | "state": "schema", |
879 | 881 | "action": "function schema(schema) { $metamodel.schema(schema); }", |
880 | 882 | "core": true, |
881 | 883 | "useCoreAPI": true |
882 | 884 | }, |
883 | | - "1aee51fae51c488": { |
884 | | - "_id": "1aee51fae51c488", |
| 885 | + "1156b1d5d511ead": { |
| 886 | + "_id": "1156b1d5d511ead", |
885 | 887 | "component": "MonocoMetamodel", |
886 | 888 | "state": "type", |
887 | 889 | "action": "function type(type) { $metamodel.type(type); }", |
888 | 890 | "core": true, |
889 | 891 | "useCoreAPI": true |
890 | 892 | }, |
891 | | - "1757c11ec81428a": { |
892 | | - "_id": "1757c11ec81428a", |
| 893 | + "1d62c163391a350": { |
| 894 | + "_id": "1d62c163391a350", |
893 | 895 | "component": "MonocoSystem", |
894 | 896 | "state": "sync", |
895 | 897 | "action": "function sync() { var dump = $db.dump(); this.schemas(dump.schemas); this.types(dump.types); this.behaviors(dump.behaviors); this.components(dump.components); }", |
896 | 898 | "core": true, |
897 | 899 | "useCoreAPI": true |
898 | 900 | }, |
899 | | - "184df1440c14198": { |
900 | | - "_id": "184df1440c14198", |
| 901 | + "12cfa18e43188ed": { |
| 902 | + "_id": "12cfa18e43188ed", |
901 | 903 | "component": "e89c617b6b15d24", |
902 | 904 | "state": "main", |
903 | 905 | "action": "function main() { var monoco = $component.get('monoco'); monoco.ready(); }", |
|
0 commit comments