Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tag naming convention #40

Closed
vdogaru opened this issue Feb 23, 2016 · 2 comments
Closed

Tag naming convention #40

vdogaru opened this issue Feb 23, 2016 · 2 comments

Comments

@vdogaru
Copy link
Contributor

vdogaru commented Feb 23, 2016

  • Each tag has a unique name, which is a simple dotted name, like "com.myapp.MyFilter".
    This allows developers to encode context info directly into a tag's name.
  • Quarks does not check a tag name for compliance to this notation rule.
    Developers are encouraged to follow this convention usage in order to avoid
    name clashes with tags generated by Quarks or other Quarks applications.
  • Tags starting with 'quarks' are reserved for use by Quarks.
    A set of helper methods are used for easily creating tag names:

Is there a better place to add these to, instead of default Tagable methods?

    /**
     * Concatenates a class name and additional names to form a string where 
     * elements are separated by dots.
     * <p>
     * Empty or null names are ignored.
     */
    default String name(Class<?> clazz, String... names) {
        ...
    }

    /**
     * Concatenates the specified firstName and additional names to form a 
     * string where elements are separated by dots.
     * <p>
     * Empty or null strings are ignored.
     */
    default String name(String firstName, String... names) {
       ... 
    }
@dlaboss
Copy link
Member

dlaboss commented Feb 23, 2016

does default violate the Java8/Android rules? Maybe just a Tags class?

@vdogaru
Copy link
Contributor Author

vdogaru commented Mar 23, 2016

@vdogaru vdogaru closed this as completed Mar 23, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants