B4J Question Is there a standard way to document and code B4J libraries?

Discussion in 'B4J Questions' started by B4JExplorer, Mar 10, 2015.

  1. B4JExplorer

    B4JExplorer Active Member Licensed User


    Do we have any kind of recommended way, to develop class libraries, in B4J?

    In other words, when we want a developer to be able to see the description of a method, in a picklist from the xml description, where do we place the description comments?

    Also, is it possible to generate javadoc for the B4J libraries?

    Finally, does B4J have a recommended naming convention? I use a modified hungarian notation, but am open to changing that style.
  2. Erel

    Erel Administrator Staff Member Licensed User

    You are asking about libraries created with B4J, right?

    The comments above the subs will be added to the xml file automatically.

    No. However there is a tool in the forum that allows you to convert the xml file to the forum bbcode: http://www.b4x.com/android/forum/threads/18564/#content

    See the (simple) naming convention that is used in all the core libraries.
    B4JExplorer likes this.
  3. dilettante

    dilettante Active Member Licensed User

    It lookes like CamelCaps for class members mixed with camelBack for arguments.

    Sometimes a "usage" suffix (e.g. srcOffset) is added but generally nothing like a type prefix (i.e. no strSearch, it would be just search or Search).
    Last edited: Mar 11, 2015
    B4JExplorer likes this.
  4. Erel

    Erel Administrator Staff Member Licensed User

    I usually use CamelCaps.
    B4JExplorer likes this.
  5. B4JExplorer

    B4JExplorer Active Member Licensed User

    Sounds good, thanks Erel/dilettante.
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice