property annotations for documentation of formatter properties v_0
authorFrantišek Kučera <franta-hg@frantovo.cz>
Sat, 15 Aug 2015 10:04:28 +0200
branchv_0
changeset 205d6624c3b146a
parent 204 2805fea90278
child 206 e2f24eea8543
property annotations for documentation of formatter properties
java/sql-dk/src/info/globalcode/sql/dk/configuration/PropertyDeclaration.java
java/sql-dk/src/info/globalcode/sql/dk/configuration/PropertyDeclarations.java
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/java/sql-dk/src/info/globalcode/sql/dk/configuration/PropertyDeclaration.java	Sat Aug 15 10:04:28 2015 +0200
     1.3 @@ -0,0 +1,49 @@
     1.4 +/**
     1.5 + * SQL-DK
     1.6 + * Copyright © 2015 František Kučera (frantovo.cz)
     1.7 + *
     1.8 + * This program is free software: you can redistribute it and/or modify
     1.9 + * it under the terms of the GNU General Public License as published by
    1.10 + * the Free Software Foundation, either version 3 of the License, or
    1.11 + * (at your option) any later version.
    1.12 + *
    1.13 + * This program is distributed in the hope that it will be useful,
    1.14 + * but WITHOUT ANY WARRANTY; without even the implied warranty of
    1.15 + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    1.16 + * GNU General Public License for more details.
    1.17 + *
    1.18 + * You should have received a copy of the GNU General Public License
    1.19 + * along with this program. If not, see <http://www.gnu.org/licenses/>.
    1.20 + */
    1.21 +package info.globalcode.sql.dk.configuration;
    1.22 +
    1.23 +import java.lang.annotation.ElementType;
    1.24 +import java.lang.annotation.Repeatable;
    1.25 +import java.lang.annotation.Retention;
    1.26 +import static java.lang.annotation.RetentionPolicy.RUNTIME;
    1.27 +import java.lang.annotation.Target;
    1.28 +
    1.29 +/**
    1.30 + *
    1.31 + * @author Ing. František Kučera (frantovo.cz)
    1.32 + */
    1.33 +@Retention(RUNTIME)
    1.34 +@Target({ElementType.TYPE})
    1.35 +@Repeatable(PropertyDeclarations.class)
    1.36 +public @interface PropertyDeclaration {
    1.37 +
    1.38 +	/**
    1.39 +	 * @return name of the property
    1.40 +	 */
    1.41 +	String name();
    1.42 +
    1.43 +	/**
    1.44 +	 * @return data type of the value: String, numbers, Boolean or Enum
    1.45 +	 */
    1.46 +	Class type();
    1.47 +
    1.48 +	/**
    1.49 +	 * @return documentation for the users
    1.50 +	 */
    1.51 +	String description();
    1.52 +}
     2.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     2.2 +++ b/java/sql-dk/src/info/globalcode/sql/dk/configuration/PropertyDeclarations.java	Sat Aug 15 10:04:28 2015 +0200
     2.3 @@ -0,0 +1,35 @@
     2.4 +/**
     2.5 + * SQL-DK
     2.6 + * Copyright © 2015 František Kučera (frantovo.cz)
     2.7 + *
     2.8 + * This program is free software: you can redistribute it and/or modify
     2.9 + * it under the terms of the GNU General Public License as published by
    2.10 + * the Free Software Foundation, either version 3 of the License, or
    2.11 + * (at your option) any later version.
    2.12 + *
    2.13 + * This program is distributed in the hope that it will be useful,
    2.14 + * but WITHOUT ANY WARRANTY; without even the implied warranty of
    2.15 + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    2.16 + * GNU General Public License for more details.
    2.17 + *
    2.18 + * You should have received a copy of the GNU General Public License
    2.19 + * along with this program. If not, see <http://www.gnu.org/licenses/>.
    2.20 + */
    2.21 +package info.globalcode.sql.dk.configuration;
    2.22 +
    2.23 +import java.lang.annotation.ElementType;
    2.24 +import java.lang.annotation.Retention;
    2.25 +import static java.lang.annotation.RetentionPolicy.RUNTIME;
    2.26 +import java.lang.annotation.Target;
    2.27 +
    2.28 +/**
    2.29 + *
    2.30 + * @author Ing. František Kučera (frantovo.cz)
    2.31 + */
    2.32 +@Retention(RUNTIME)
    2.33 +@Target({ElementType.TYPE})
    2.34 +public @interface PropertyDeclarations {
    2.35 +
    2.36 +	PropertyDeclaration[] value();
    2.37 +
    2.38 +}