подправил стили для кода примеров. Добавил std, v2, tools, v2.ll.

This commit is contained in:
Aleksey Chichenkov 2018-09-25 15:14:18 +03:00
parent 2c27a64ea0
commit 73f3735bb6
54 changed files with 1579 additions and 342 deletions

View file

@ -0,0 +1,12 @@
/** @typedef {Models.Model.Groups.BaseGroup} ModelBaseGroup */
/**
*
* @group manager
* @class BaseGroup
* @extends Models.Model.Groups.Group
* @memberof Models.Model.Groups
*/
var BaseGroup = function () {
};

View file

@ -0,0 +1,8 @@
/**
*
* @group manager
* @class BGComponents
* @extends Models.Model.Groups.Group.Components
* @memberof Models.Model.Groups.Group
*/
var BGComponents = function () {};

View file

@ -0,0 +1,54 @@
/** @typedef {Models.Model.Groups.Group.Components.Component.Attributes.Attribute} ComponentAttribute */
/**
*
* @group manager
* @class Attribute
* @extends item
* @memberof Models.Model.Groups.Group.Components.Component.Attributes
*/
var Attribute = function () {
/**
*
* @public
* @function name
* @memberof Models.Model.Groups.Group.Components.Component.Attributes.Attribute
* @returns {v2.string}
*/
this.name = function () {
};
/**
*
* @public
* @function type
* @memberof Models.Model.Groups.Group.Components.Component.Attributes.Attribute
* @returns {v2.type}
*/
this.type = function () {
};
/**
*
* @public
* @function last_change
* @memberof Models.Model.Groups.Group.Components.Component.Attributes.Attribute
* @returns {v2.time}
*/
this.last_change = function () {
};
/**
*
* @public
* @function value
* @memberof Models.Model.Groups.Group.Components.Component.Attributes.Attribute
* @returns {v2}
*/
this.value = function () {
};
};

View file

@ -0,0 +1,31 @@
/**
*
* @group manager
* @class Attributes
* @extends manager
* @memberof Models.Model.Groups.Group.Components.Component
*/
var Attributes = function () {
/**
*
* @public
* @function attributes
* @memberof Models.Model.Groups.Group.Components.Component.Attributes
* @returns {v2.map(v2.string, v2.vc)}
*/
this.attributes = function () {
};
/**
*
* @public
* @function get
* @memberof Models.Model.Groups.Group.Components.Component.Attributes
* @param name {v2.string}
* @returns {tools.promise(ModelComponent)}
*/
this.get = function (name) {
};
};

View file

@ -0,0 +1,44 @@
/** @typedef {Models.Model.Groups.Group.Components.Component} ModelComponent */
/**
*
* @group manager
* @class Component
* @extends item
* @memberof Models.Model.Groups.Group.Components
*/
var Component = function () {
/**
*
* @public
* @function address
* @memberof Models.Model.Groups.Group.Components.Component
* @returns {v2.address}
*/
this.address = function () {
};
/**
*
* @public
* @function attributes
* @memberof Models.Model.Groups.Group.Components.Component
* @returns {v2.map(v2.string, v2.vc)}
*/
this.attributes = function () {
};
/**
*
* @public
* @function address
* @memberof Models.Model.Groups.Group.Components.Component
* @param attrName {v2.string}
* @returns {tools.promise(ComponentAttribute)}
*/
this.get = function (attrName) {
};
};

View file

@ -0,0 +1,43 @@
/**
*
* @group manager
* @class Components
* @extends manager
* @memberof Models.Model.Groups.Group
*/
var Components = function () {
/**
*
* @public
* @function is_component_exist
* @memberof Models.Model.Groups.Group.Components
* @param componentId {v2.string}
* @returns {boolean}
*/
this.is_component_exist = function (componentId) {
};
/**
*
* @public
* @function get
* @memberof Models.Model.Groups.Group.Components
* @param componentId {v2.string}
* @returns {tools.promise(ModelComponent)}
*/
this.get = function (componentId) {
};
/**
*
* @public
* @function components
* @memberof Models.Model.Groups.Group.Components
* @returns {tools.promise(v2.set(v2.string))}
*/
this.components = function () {
};
};

View file

@ -0,0 +1,44 @@
/** @typedef {Models.Model.Groups.Group} ModelGroup */
/**
*
* @group manager
* @class Group
* @extends item
* @memberof Models.Model.Groups
*/
var Group = function () {
/**
*
* @public
* @function components
* @memberof Models.Model.Groups.Group
* @returns {tools.promise()}
*/
this.components = function () {
};
/**
*
* @public
* @function attributes
* @memberof Models.Model.Groups.Group
* @returns {v2.map(v2.string, v2.vc)}
*/
this.attributes = function () {
};
/**
*
* @public
* @function get
* @memberof Models.Model.Groups.Group
* @param componentId {v2.string}
* @returns {tools.promise(ModelComponent)}
*/
this.get = function (componentId) {
}
};

View file

@ -0,0 +1,42 @@
/**
*
* @group manager
* @class Groups
* @extends manager
* @memberof Models.Model
*/
var Groups = function () {
/**
*
* @public
* @function all
* @memberof Models.Model.Groups
* @returns {v2.deque(v2.string)}
*/
this.all = function () {
};
/**
*
* @public
* @function is_group_exist
* @memberof Models.Model.Groups
* @returns {boolean}
*/
this.is_group_exist = function () {
};
/**
*
* @public
* @function get
* @memberof Models.Model.Groups
* @param alias {v2.string}
* @returns {tools.promise(Models.Model.Groups.Group)}
*/
this.get = function (alias) {
}
};

View file

@ -5,6 +5,7 @@
*
* @group manager
* @namespace Models
* @extends manager
*/
function Models() {
/**

View file

@ -7,6 +7,15 @@
* @memberof Models
*/
function Model() {
/**
*
* @public
* @name static
* @type {Models.Model.static_data}
*/
this.static = new Models.Model.static_data();
/**
*
* @public
@ -29,6 +38,19 @@ function Model() {
};
/**
*
* @public
* @function get_group
* @memberof Models.Model
* @param groupType {v2.model_type}
* @returns {tools.promise(ModelGroup)}
*/
this.get_group = function(groupType) {
};
/**
*
* @public

View file

@ -0,0 +1,62 @@
/**
* @class static
* @memberof Models.Model
* @extends item
*/
var static_data = function () {
/**
*
* @public
* @function label_attrs
* @memberof Models.Model.static
* @returns {v2.set(v2.string)}
*/
this.label_attrs = function () {
};
/**
*
* @public
* @function popup_attrs
* @memberof Models.Model.static
* @returns {v2.set(v2.string)}
*/
this.popup_attrs = function () {
};
/**
*
* @public
* @function is_container
* @memberof Models.Model.static
* @returns {v2.boolean}
*/
this.is_container = function () {
};
/**
*
* @public
* @function base_component_type
* @memberof Models.Model.static
* @returns {v2.model_type}
*/
this.base_component_type = function () {
};
/**
*
* @public
* @function touch
* @memberof Models.Model.static
* @returns {tools.promise}
*/
this.touch = function () {
}
};

View file

@ -0,0 +1,51 @@
/** @typedef {Publishers.Publisher.Items.Item.Attributes.Attribute} PublisherItemAttribute */
/**
*
* @group manager
* @class Attribute
* @memberof Publishers.Publisher.Items.Item.Attributes
*/
var Attribute = function () {
/**
*
* @name s_size_change
* @public
* @memberof Publishers.Publisher.Items.Item.Attributes.Attribute
* @type {number}
*/
this.s_size_change = -1;
/**
*
* @public
* @function name
* @memberof Publishers.Publisher.Items.Item.Attributes.Attribute
* @returns {v2.string}
*/
this.name = function () {
};
/**
*
* @public
* @function value
* @memberof Publishers.Publisher.Items.Item.Attributes.Attribute
* @returns {v2}
*/
this.value = function () {
};
/**
*
* @public
* @function type
* @memberof Publishers.Publisher.Items.Item.Attributes.Attribute
* @returns {v2.type}
*/
this.type = function () {
}
};

View file

@ -0,0 +1,32 @@
/**
*
* @group manager
* @class Attributes
* @memberof Publishers.Publisher.Items.Item
*/
var Attributes = function () {
/**
*
* @public
* @function get
* @memberof Publishers.Publisher.Items.Item.Attributes
* @param _id {v2.integer}
* @returns {tools.promise(PublisherItemAttribute)}
*/
this.get = function (_id) {
};
/**
*
* @public
* @function attributes
* @memberof Publishers.Publisher.Items.Item.Attributes
* @returns {v2.list(v2.string)}
*/
this.attributes = function () {}
};

View file

@ -0,0 +1,32 @@
/** @typedef {Publishers.Publisher.Items.Item} PublisherItem */
/**
*
* @group manager
* @class Item
* @memberof Publishers.Publisher.Items
*/
var Item = function () {
/**
*
* @function id
* @public
* @memberof Publishers.Publisher.Items.Item
* @type {v2.integer}
*/
this.id = function () {
};
/**
*
* @public
* @function get
* @memberof Publishers.Publisher.Items.Item
* @param _index {v2.integer}
* @returns {tools.promise(PublisherItemAttribute)}
*/
this.get = function (_index) {
};
};

View file

@ -1,151 +0,0 @@
/** @typedef {Publishers.Publisher.Items.Item} PublisherItem */
/** @typedef {Publishers.Publisher.Items.Item.Attributes.Attribute} PublisherItemAttribute */
/**
*
* @group manager
* @class Items
* @memberof Publishers.Publisher
*/
var Items = function () {
/**
*
* @public
* @function get
* @memberof Publishers.Publisher.Items
* @param _id {v2.integer}
* @returns {tools.promise(PublisherItem)}
*/
this.get = function (_id) {
};
/**
*
* @public
* @function is_exist
* @memberof Publishers.Publisher.Items
* @param _id {v2.integer}
* @returns {boolean}
*/
this.is_exist = function (_id) {
};
/**
*
* @group manager
* @class Item
* @memberof Publishers.Publisher.Items
*/
var Item = function () {
/**
*
* @name id
* @public
* @memberof Publishers.Publisher.Items.Item
* @type {v2.integer}
*/
this.id = function () {
};
/**
*
* @public
* @function get
* @memberof Publishers.Publisher.Items.Item
* @param _index {v2.integer}
* @returns {tools.promise(PublisherItemAttribute)}
*/
this.get = function (_index) {
};
};
};
/**
*
* @group manager
* @class Attributes
* @memberof Publishers.Publisher.Items.Item
*/
var Attributes = function () {
/**
*
* @public
* @function get
* @memberof Publishers.Publisher.Items.Item.Attributes
* @param _id {v2.integer}
* @returns {tools.promise(PublisherItemAttribute)}
*/
this.get = function (_id) {
};
/**
*
* @public
* @function attributes
* @memberof Publishers.Publisher.Items.Item.Attributes
* @returns {v2.list(v2.string)}
*/
this.attributes = function () {}
/**
*
* @group manager
* @class Attribute
* @memberof Publishers.Publisher.Items.Item.Attributes
*/
var Attribute = function () {
/**
*
* @name s_size_change
* @public
* @memberof Publishers.Publisher.Items.Item.Attributes.Attribute
* @type {number}
*/
this.s_size_change = -1;
/**
*
* @public
* @function name
* @memberof Publishers.Publisher.Items.Item.Attributes.Attribute
* @returns {v2.string}
*/
this.name = function () {
};
/**
*
* @public
* @function value
* @memberof Publishers.Publisher.Items.Item.Attributes.Attribute
* @returns {v2}
*/
this.value = function () {
};
/**
*
* @public
* @function type
* @memberof Publishers.Publisher.Items.Item.Attributes.Attribute
* @returns {v2.type}
*/
this.type = function () {
}
};
};

View file

@ -0,0 +1,34 @@
/**
*
* @group manager
* @class Items
* @memberof Publishers.Publisher
*/
var Items = function () {
/**
*
* @public
* @function get
* @memberof Publishers.Publisher.Items
* @param _id {v2.integer}
* @returns {tools.promise(PublisherItem)}
*/
this.get = function (_id) {
};
/**
*
* @public
* @function is_exist
* @memberof Publishers.Publisher.Items
* @param _id {v2.integer}
* @returns {boolean}
*/
this.is_exist = function (_id) {
};
};

View file

@ -1,3 +1,5 @@
/** @typedef {Trees.GlobalTree.Node.Children} NodeChildren */
/**
* Интерфейс позволяющей пользователю работать с потомками ноды
*
@ -29,7 +31,7 @@ function Children() {
*
* @public
* @function get
* @returns {v2.list(v2.integer.type)}
* @returns {v2.list(v2.integer)}
* @memberof Trees.GlobalTree.Node.Children
*/
this.children = function(attributeName) {

View file

@ -63,7 +63,7 @@ function Node() {
* Доступ к менеджеру детей
* @public
* @function cm
* @returns {Children}
* @returns {NodeChildren}
* @memberof Trees.GlobalTree.Node
*/
this.cm = function() {

View file

@ -1,4 +1,4 @@
/** @typedef {Trees.GlobalTree.Node.NodeTypes.NodeType} NodeType
/** @typedef {Trees.GlobalTree.Node.NodeTypes.NodeType} NodeType */
/**
*

View file

@ -1,14 +1,24 @@
/**
/**
* Менеджер деревьев.
* Представляет собой интерфейс для доступа ко всем деревьям
* Позволяет по тегу дерева получить на него ссылку.
* На текущий момент содержит в себе:
* - global_tree (Основное дерево)
* - global_attribute_tree (Дерево, которое предоставляет доступ к атрибутам)
* - desktop_tree (Представляет рабочий стол)
* - remote_modules_tree (Представляет собой дерево сборщиков)
* - scheme_tree (Топология)
* - user_attribute_tree (Пользовательские данные)
* На текущий момент содержит в себе:
*
* @example
* // Работа с деревом
* // Доступ к менеджеру деревьев находится в переменной ps.pl.tm (провайдеры -> мастер платформа -> менеджер деревьев)
* // доступ к конкретному дереву осуществляется по тагу дерева например ("st", "rmt", "uat")
* // где st - дерево топологии, rmt - дерево сборщиков данных, uat - дерево в котором хранится информация о
* // данных пользователя
* ps.pl.tm(new v2.string("rmt")).then(function(ref){
* // ref - это ссылка на объект
* // метод value возвращает целевой объект. В данном случае дерево {@type Trees.GlobalTree}
* var tree = ref.value();
* }, function(err){
* // в случае неудачи придет ошибка.
* // обычно в ошибке содержится три переменные err - код ошибки, message - краткое описание, sub - если к этому
* // привела другая ошибка внутри системы.
* })
*
* @group manager
* @namespace Trees
@ -38,4 +48,4 @@ function Trees() {
this.is_tree_exist = function (treeTag) {
}
}
}