Skip to content

Commit

Permalink
formatting & cleaning up code
Browse files Browse the repository at this point in the history
  • Loading branch information
jbax committed Jul 15, 2015
1 parent 312ce78 commit 8d8dc7f
Show file tree
Hide file tree
Showing 198 changed files with 1,733 additions and 1,721 deletions.
355 changes: 190 additions & 165 deletions LICENSE-2.0.html

Large diffs are not rendered by default.

7 changes: 4 additions & 3 deletions pom.xml
@@ -1,4 +1,5 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">

<modelVersion>4.0.0</modelVersion>
<groupId>com.univocity</groupId>
Expand Down Expand Up @@ -207,7 +208,7 @@
</goals>
</pluginExecutionFilter>
<action>
<ignore />
<ignore/>
</action>
</pluginExecution>
<pluginExecution>
Expand All @@ -221,7 +222,7 @@
</goals>
</pluginExecutionFilter>
<action>
<ignore />
<ignore/>
</action>
</pluginExecution>
</pluginExecutions>
Expand Down
@@ -1,12 +1,12 @@
/*******************************************************************************
* Copyright 2014 uniVocity Software Pty Ltd
*
* <p/>
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* <p/>
* http://www.apache.org/licenses/LICENSE-2.0
*
* <p/>
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Expand All @@ -15,11 +15,11 @@
******************************************************************************/
package com.univocity.parsers.annotations;

import java.lang.annotation.*;

import com.univocity.parsers.common.processor.*;
import com.univocity.parsers.conversions.*;

import java.lang.annotation.*;

/**
* Indicates that parsed values such as "y", "No" or "null" should be interpreted as boolean values.
* If a parsed value exists in {@link BooleanString#trueStrings()}, then the field will receive true.
Expand All @@ -37,7 +37,7 @@
*/
@Retention(RetentionPolicy.RUNTIME)
@Inherited
@Target(value = { ElementType.FIELD })
@Target(value = {ElementType.FIELD})
public @interface BooleanString {
/**
* A set of Strings that represent the boolean value {@code true} (e.g. "y", "yes", "1")
Expand Down
15 changes: 7 additions & 8 deletions src/main/java/com/univocity/parsers/annotations/Convert.java
@@ -1,12 +1,12 @@
/*******************************************************************************
* Copyright 2014 uniVocity Software Pty Ltd
*
* <p/>
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* <p/>
* http://www.apache.org/licenses/LICENSE-2.0
*
* <p/>
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Expand All @@ -15,11 +15,11 @@
******************************************************************************/
package com.univocity.parsers.annotations;

import java.lang.annotation.*;

import com.univocity.parsers.common.processor.*;
import com.univocity.parsers.conversions.*;

import java.lang.annotation.*;

/**
* Assigns a custom implementation of {@link Conversion} to be executed when writing to/reading from the field.
*
Expand All @@ -35,15 +35,14 @@
*/
@Retention(RetentionPolicy.RUNTIME)
@Inherited
@Target(value = { ElementType.FIELD })
@Target(value = {ElementType.FIELD})
public @interface Convert {

/**
* A user provided implementation of {@link Conversion} which will be instantiated using the arguments provided by {@link Convert#args()}
* @return custom class used to convert values
*/
@SuppressWarnings("rawtypes")
Class<? extends Conversion> conversionClass();
@SuppressWarnings("rawtypes") Class<? extends Conversion> conversionClass();

/**
* The arguments to use when invoking the constructor of the class given by {@link Convert#conversionClass()}.
Expand Down
14 changes: 7 additions & 7 deletions src/main/java/com/univocity/parsers/annotations/EnumOptions.java
@@ -1,12 +1,12 @@
/*******************************************************************************
* Copyright 2015 uniVocity Software Pty Ltd
*
* <p/>
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* <p/>
* http://www.apache.org/licenses/LICENSE-2.0
*
* <p/>
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Expand All @@ -15,11 +15,11 @@
******************************************************************************/
package com.univocity.parsers.annotations;

import java.lang.annotation.*;

import com.univocity.parsers.common.processor.*;
import com.univocity.parsers.conversions.*;

import java.lang.annotation.*;

/**
* The {@code EnumSelector} annotation is meant to be used in conjunction with enumeration attributes.
*
Expand Down Expand Up @@ -50,7 +50,7 @@
*/
@Retention(RetentionPolicy.RUNTIME)
@Inherited
@Target(value = { ElementType.FIELD, ElementType.METHOD })
@Target(value = {ElementType.FIELD, ElementType.METHOD})
public @interface EnumOptions {

/**
Expand All @@ -63,7 +63,7 @@
* </ul>
* @return the sequence of properties of the enumeration type to match against the parsed input.
*/
EnumSelector[] selectors() default { EnumSelector.NAME, EnumSelector.ORDINAL, EnumSelector.STRING };
EnumSelector[] selectors() default {EnumSelector.NAME, EnumSelector.ORDINAL, EnumSelector.STRING};

/**
*
Expand Down
12 changes: 6 additions & 6 deletions src/main/java/com/univocity/parsers/annotations/Format.java
@@ -1,12 +1,12 @@
/*******************************************************************************
* Copyright 2014 uniVocity Software Pty Ltd
*
* <p/>
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* <p/>
* http://www.apache.org/licenses/LICENSE-2.0
*
* <p/>
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Expand All @@ -15,11 +15,11 @@
******************************************************************************/
package com.univocity.parsers.annotations;

import java.lang.annotation.*;

import com.univocity.parsers.common.processor.*;
import com.univocity.parsers.conversions.*;

import java.lang.annotation.*;

/**
* Indicates that a parsed value is formatted and must be parsed before being assigned.
* <p>The {@link Conversion} type assigned to this field will depend on its type.</p>
Expand All @@ -44,7 +44,7 @@
*/
@Retention(RetentionPolicy.RUNTIME)
@Inherited
@Target(value = { ElementType.FIELD, ElementType.METHOD })
@Target(value = {ElementType.FIELD, ElementType.METHOD})
public @interface Format {
/**
* Formats that define how a value can be formatted. When reading, the values parsed from the input will be parsed according to the specified format. If multiple formats
Expand Down
12 changes: 6 additions & 6 deletions src/main/java/com/univocity/parsers/annotations/Headers.java
@@ -1,12 +1,12 @@
/*******************************************************************************
* Copyright 2015 uniVocity Software Pty Ltd
*
* <p/>
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* <p/>
* http://www.apache.org/licenses/LICENSE-2.0
*
* <p/>
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Expand All @@ -15,11 +15,11 @@
******************************************************************************/
package com.univocity.parsers.annotations;

import java.lang.annotation.*;

import com.univocity.parsers.common.*;
import com.univocity.parsers.common.processor.*;

import java.lang.annotation.*;

/**
* The {@code Headers} annotation allows java beans to configure how to handle field names in a given input/output
*
Expand Down Expand Up @@ -48,7 +48,7 @@
*/
@Retention(RetentionPolicy.RUNTIME)
@Inherited
@Target(value = { ElementType.TYPE })
@Target(value = {ElementType.TYPE})
public @interface Headers {

/**
Expand Down
12 changes: 6 additions & 6 deletions src/main/java/com/univocity/parsers/annotations/LowerCase.java
@@ -1,12 +1,12 @@
/*******************************************************************************
* Copyright 2014 uniVocity Software Pty Ltd
*
* <p/>
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* <p/>
* http://www.apache.org/licenses/LICENSE-2.0
*
* <p/>
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Expand All @@ -15,11 +15,11 @@
******************************************************************************/
package com.univocity.parsers.annotations;

import java.lang.annotation.*;

import com.univocity.parsers.common.processor.*;
import com.univocity.parsers.conversions.*;

import java.lang.annotation.*;

/**
* Indicates the String value of a field must be converted to lower case using {@link LowerCaseConversion}.
*
Expand All @@ -35,7 +35,7 @@
*/
@Retention(RetentionPolicy.RUNTIME)
@Inherited
@Target(value = { ElementType.FIELD })
@Target(value = {ElementType.FIELD})
public @interface LowerCase {

}
12 changes: 6 additions & 6 deletions src/main/java/com/univocity/parsers/annotations/NullString.java
@@ -1,12 +1,12 @@
/*******************************************************************************
* Copyright 2014 uniVocity Software Pty Ltd
*
* <p/>
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* <p/>
* http://www.apache.org/licenses/LICENSE-2.0
*
* <p/>
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Expand All @@ -15,11 +15,11 @@
******************************************************************************/
package com.univocity.parsers.annotations;

import java.lang.annotation.*;

import com.univocity.parsers.common.processor.*;
import com.univocity.parsers.conversions.*;

import java.lang.annotation.*;

/**
* Indicates that parsed values such as "", "?" or "null" should be interpreted as null. If a parsed value exists in {@link NullString#nulls()}, then the field must be set to null.
* <p>A {@link NullStringConversion} will be assigned to this field
Expand All @@ -36,7 +36,7 @@

@Retention(RetentionPolicy.RUNTIME)
@Inherited
@Target(value = { ElementType.FIELD, ElementType.METHOD })
@Target(value = {ElementType.FIELD, ElementType.METHOD})
public @interface NullString {
/**
* A set of Strings that represent a null value instead of a valid String (e.g. "?", "empty", "null" )
Expand Down
12 changes: 6 additions & 6 deletions src/main/java/com/univocity/parsers/annotations/Parsed.java
@@ -1,12 +1,12 @@
/*******************************************************************************
* Copyright 2014 uniVocity Software Pty Ltd
*
* <p/>
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* <p/>
* http://www.apache.org/licenses/LICENSE-2.0
*
* <p/>
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Expand All @@ -15,12 +15,12 @@
******************************************************************************/
package com.univocity.parsers.annotations;

import java.lang.annotation.*;

import com.univocity.parsers.annotations.helpers.*;
import com.univocity.parsers.common.processor.*;
import com.univocity.parsers.conversions.*;

import java.lang.annotation.*;

/**
* Indicates the field is parsed. If the annotated field type is not a String, it will be automatically converted using one
* of the existing {@link Conversion} implementations in package {@link com.univocity.parsers.conversions}.
Expand All @@ -40,7 +40,7 @@
*/
@Retention(RetentionPolicy.RUNTIME)
@Inherited
@Target(value = { ElementType.FIELD, ElementType.METHOD })
@Target(value = {ElementType.FIELD, ElementType.METHOD})
public @interface Parsed {
/**
* The field name in a parsed record
Expand Down
12 changes: 6 additions & 6 deletions src/main/java/com/univocity/parsers/annotations/Replace.java
@@ -1,12 +1,12 @@
/*******************************************************************************
* Copyright 2014 uniVocity Software Pty Ltd
*
* <p/>
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* <p/>
* http://www.apache.org/licenses/LICENSE-2.0
*
* <p/>
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Expand All @@ -15,11 +15,11 @@
******************************************************************************/
package com.univocity.parsers.annotations;

import java.lang.annotation.*;

import com.univocity.parsers.common.processor.*;
import com.univocity.parsers.conversions.*;

import java.lang.annotation.*;

/**
* Indicates the String value of a field must have some of its contents replaced using {@link RegexConversion}.
*
Expand All @@ -35,7 +35,7 @@
*/
@Retention(RetentionPolicy.RUNTIME)
@Inherited
@Target(value = { ElementType.FIELD, ElementType.METHOD })
@Target(value = {ElementType.FIELD, ElementType.METHOD})
public @interface Replace {
/**
* The regular expression to be executed against the String value of the annotated field
Expand Down

0 comments on commit 8d8dc7f

Please sign in to comment.