First batch of JavaDoc that is being done.

-Added: JavaDoc for Map Interfaces.
-Added: JavaDoc for Abstract Map/Collection/Set
-Added: Ignore JavaDoc for tests/builder code.
-Added: More JavaDoc for Arrays.
This commit is contained in:
2021-04-25 03:45:57 +02:00
parent 199f50eb32
commit 2ca14f4d4f
48 changed files with 569 additions and 7 deletions
@@ -1,5 +1,6 @@
package speiger.src.builder;
@SuppressWarnings("javadoc")
public enum ClassType
{
BOOLEAN("boolean", "Boolean", "Boolean", "booleans", "BOOLEAN", "false"),
@@ -14,6 +14,7 @@ import speiger.src.builder.mappers.LineMapper;
import speiger.src.builder.mappers.SimpleMapper;
import speiger.src.builder.processor.TemplateProcess;
@SuppressWarnings("javadoc")
public class GlobalVariables
{
List<IMapper> operators = new ArrayList<>();
@@ -71,6 +72,8 @@ public class GlobalVariables
}
addComment("@ArrayType", "@param <%s> the type of array that the operation should be applied");
addComment("@Type", "@param <%s> the type of elements maintained by this Collection");
addValueComment("@ValueArrayType", "@param <%s> the type of array that the operation should be applied");
addValueComment("@ValueType", "@param <%s> the type of elements maintained by this Collection");
addAnnontion("@PrimitiveOverride", "@Override");
addSimpleMapper("@PrimitiveDoc", "");
addAnnontion("@Primitive", "@Deprecated");
@@ -331,6 +334,12 @@ public class GlobalVariables
else operators.add(new LineMapper(type.name()+"["+pattern+"]", pattern));
}
private void addValueComment(String pattern, String value)
{
if(valueType == ClassType.OBJECT) operators.add(new InjectMapper(valueType.name()+"["+pattern+"]", pattern, value).removeBraces());
else operators.add(new LineMapper(valueType.name()+"["+pattern+"]", pattern));
}
private InjectMapper addInjectMapper(String pattern, String replacement)
{
InjectMapper mapper = new InjectMapper(type.name()+"["+pattern+"]", pattern, replacement);
@@ -15,6 +15,7 @@ import java.util.function.Consumer;
import speiger.src.builder.processor.TemplateProcess;
import speiger.src.builder.processor.TemplateProcessor;
@SuppressWarnings("javadoc")
public class PrimitiveCollectionsBuilder extends TemplateProcessor
{
Map<String, EnumSet<ClassType>> blocked = new HashMap<>();