Coder Social home page Coder Social logo

sobascript.mapper's Introduction

Mapper for SobaScript components and their nodes.

-- #SobaScript

Extensible Modular Scripting Programming Language.

https://github.com/3F/SobaScript

Build status release-src License NuGet package

Build history

License

Licensed under the MIT License

Copyright (c) 2014-2019  Denis Kuzmin < [email protected] > GitHub/3F

[ โ˜• Donate ]

SobaScript.Mapper contributors: https://github.com/3F/SobaScript.Mapper/graphs/contributors

Mapper

This helps to describe your component for code completion (Intellisense), for generating the documentation files, etc.

PropertyAttribute

To describe the properties. For example:

[Property("propertyName", "Description of the property", CValType.Boolean, CValType.Boolean)]
public string yourLogic()
{
   ...
}
[Property(
    "IsBuildable", 
    "Gets or Sets whether the project or project item configuration can be built.", 
    "find", 
    "stProjectConf", 
    CValType.Boolean, 
    CValType.Boolean
)]

Basic Syntax:

[Property(string name, string description, CValType get, CValType set)]
[Property(string name, string parent, string method, CValType get, CValType set)]

Note:

  • An optional parent argument is used for linking to parent property/method/etc.
  • An method argument must contain the real method name who implements the parent element (property/method etc.)

MethodAttribute

To describe the methods/functions. For example:

[
    Method
    (
        "call", 
        "Caller of executable files with arguments.", 
        new string[] { "name", "args" }, 
        new string[] { "Executable file", "Arguments" }, 
        CValType.Void, 
        CValType.String, CValType.String
    )
]
protected string stCall(string data, bool stdOut, bool silent)
{
    ...
}

Basic Syntax:

[Method(string name, string description, CValType ret, params CValType[] args)]
[Method(string name, string parent, string method, CValType ret, params CValType[] args)]

Note:

  • An optional parent argument is used for linking to parent property/method/etc.
  • An method argument must contain the real method name who implements the parent element (property/method etc.)

ComponentAttribute

To describe the new component. For example:

[Component("File", "I/O operations")]
public class FileComponent: Component, IComponent
{
    ...
}

Basic Syntax:

[Component(string name, string description)]

Aliases

[Component("Primary", new[]{ "Alias1", "Alias2", "Alias3" }, "description")]

DefinitionAttribute

To describe the any definition. For example:

[Definition("(true) { }", "Conditionals statements\n\n(1 > 2) {\n ... \n}")]
public class ConditionComponent: Component, IComponent
{
    ...
}
[Definition("var name", "Get data from variable the 'name'")]
[Definition("var name = data", "Set the 'data' for variable the 'name'")]

Syntax:

[Definition(string name, string description)]

sobascript.mapper's People

Contributors

3f avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.