Skip to content

Commit

Permalink
Updated org.dozer to com.github.dozermapper.core (#582)
Browse files Browse the repository at this point in the history
  • Loading branch information
garethahealy committed Apr 2, 2018
1 parent 4b0931a commit c0de047
Show file tree
Hide file tree
Showing 1,502 changed files with 45,748 additions and 47,099 deletions.
3 changes: 2 additions & 1 deletion building-tools/src/main/resources/strict-checkstyle.xml
Expand Up @@ -133,7 +133,8 @@

<!-- Checks that most tokens are surrounded by whitespace. RCURLY is omitted so we can do stuff like "new Thread(){...}.start()". -->
<module name="WhitespaceAround">
<property name="tokens" value="ASSIGN, BAND, BAND_ASSIGN, BOR, BOR_ASSIGN, BSR, BSR_ASSIGN, BXOR, BXOR_ASSIGN, COLON, DIV, DIV_ASSIGN, EQUAL, GE, GT, LAND, LCURLY, LE, LITERAL_ASSERT, LITERAL_CATCH, LITERAL_DO, LITERAL_ELSE, LITERAL_FINALLY, LITERAL_FOR, LITERAL_IF, LITERAL_RETURN, LITERAL_SYNCHRONIZED, LITERAL_TRY, LITERAL_WHILE, LOR, LT, MINUS, MINUS_ASSIGN, MOD, MOD_ASSIGN, NOT_EQUAL, PLUS, PLUS_ASSIGN, QUESTION, SL, SLIST, SL_ASSIGN, SR, SR_ASSIGN, STAR, STAR_ASSIGN, TYPE_EXTENSION_AND"/>
<property name="tokens"
value="ASSIGN, BAND, BAND_ASSIGN, BOR, BOR_ASSIGN, BSR, BSR_ASSIGN, BXOR, BXOR_ASSIGN, COLON, DIV, DIV_ASSIGN, EQUAL, GE, GT, LAND, LCURLY, LE, LITERAL_ASSERT, LITERAL_CATCH, LITERAL_DO, LITERAL_ELSE, LITERAL_FINALLY, LITERAL_FOR, LITERAL_IF, LITERAL_RETURN, LITERAL_SYNCHRONIZED, LITERAL_TRY, LITERAL_WHILE, LOR, LT, MINUS, MINUS_ASSIGN, MOD, MOD_ASSIGN, NOT_EQUAL, PLUS, PLUS_ASSIGN, QUESTION, SL, SLIST, SL_ASSIGN, SR, SR_ASSIGN, STAR, STAR_ASSIGN, TYPE_EXTENSION_AND"/>
</module>

<!-- Ensure there is no space between the identifier of a method definition, constructor definition, method call, or constructor invocation and the left parenthesis of the parameter list. -->
Expand Down
14 changes: 7 additions & 7 deletions core/pom.xml
Expand Up @@ -33,21 +33,21 @@
<name>Dozer :: Core</name>

<properties>
<osgi.Bundle-Activator>org.dozer.osgi.Activator</osgi.Bundle-Activator>
<osgi.Bundle-Activator>com.github.dozermapper.core.osgi.Activator</osgi.Bundle-Activator>
<!--
<osgi.additional.Import-Package>
org.hibernate.proxy;version="[4.2,6)";resolution:=optional,
javassist.util.proxy;version="[3.13,4)";resolution:=optional
</osgi.additional.Import-Package>
-->
<osgi.Export-Package>org.dozer.*</osgi.Export-Package>
<osgi.Export-Package>com.github.dozermapper.core.*</osgi.Export-Package>
<!-- ServiceLoader Capability -->
<osgi.Require-Capability>
osgi.serviceloader; filter:="(osgi.serviceloader=org.dozer.DozerModule)";cardinality:=multiple;resolution:=optional,
osgi.serviceloader; filter:="(osgi.serviceloader=com.github.dozermapper.core.DozerModule)";cardinality:=multiple;resolution:=optional,
osgi.extender; filter:="(osgi.extender=osgi.serviceloader.processor)";resolution:=optional
</osgi.Require-Capability>
<osgi.SPI-Consumer>*</osgi.SPI-Consumer>

<!-- NOTE: Needs to be removed in future -->
<spotbugs.skip>true</spotbugs.skip>

Expand Down Expand Up @@ -188,7 +188,7 @@
<artifactId>maven-jar-plugin</artifactId>
<configuration>
<excludes>
<exclude>**/org/dozer/vo/**</exclude>
<exclude>**/com/github/dozermapper/core/vo/**</exclude>
<exclude>**/net/pmonks/**</exclude>
</excludes>
</configuration>
Expand Down Expand Up @@ -278,7 +278,7 @@
<configuration>
<workDirectory>${project.build.directory}/generated-resources/schemagen</workDirectory>
<includes>
org/dozer/builder/model/jaxb/**
com/github/dozermapper/core/builder/model/jaxb/**
</includes>
<transformSchemas>
<transformSchema>
Expand Down Expand Up @@ -313,7 +313,7 @@
<configuration>
<workDirectory>${project.build.directory}/generated-resources/schemagen</workDirectory>
<includes>
org/dozer/builder/model/jaxb/**
com/github/dozermapper/core/builder/model/jaxb/**
</includes>
</configuration>
</execution>
Expand Down
Expand Up @@ -13,12 +13,11 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.dozer;
package com.github.dozermapper.core;

/**
* @author Dmitry Spikhalskiy
*/
public interface BeanBuilder {
Class<?> beanClass();
Object build();

Class<?> beanClass();

Object build();
}
Expand Up @@ -13,31 +13,29 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.dozer;
package com.github.dozermapper.core;

import org.dozer.config.BeanContainer;
import com.github.dozermapper.core.config.BeanContainer;

/**
* Public custom bean factory interface.
*
* <p>
* You can configure Dozer to use custom bean factories to create new instances of destination data objects during the
* mapping process. By default Dozer just creates a new instance of any destination objects using a default constructor.
* This is sufficient for most use cases, but if you need more flexibility you can specify your own bean factories to
* instantiate the data objects.
*
* <p>
* Your custom bean factory must implement the org.dozer.BeanFactory interface.
*
* <p>
* Your custom bean factory must implement the com.github.dozermapper.core.BeanFactory interface.
* <p>
* <p>
* Note: By default the Dozer mapping engine will use the destination object class name for the bean id when invoking
* the factory.
*
* <p>
* <p>
* <a
* href="https://dozermapper.github.io/gitbook/documentation/custombeanfactories.html">
* https://dozermapper.github.io/gitbook/documentation/custombeanfactories.html</a>
*
* @author tierney.matt
*/
public interface BeanFactory {

Expand All @@ -48,8 +46,9 @@ default Object createBean(Object source, Class<?> sourceClass, String targetBean

/**
* Will be removed in 6.2. Please use {@link BeanFactory#createBean(Object, Class, String, BeanContainer)}.
* @param source obj
* @param sourceClass obj
*
* @param source obj
* @param sourceClass obj
* @param targetBeanId id
* @return bean
*/
Expand Down
Expand Up @@ -13,17 +13,13 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.dozer;
package com.github.dozermapper.core;

import org.dozer.factory.BeanCreationDirective;
import com.github.dozermapper.core.factory.BeanCreationDirective;

/**
* @author Dmitry Spikhalskiy
*/
public interface BeanGeneralCreationStrategy<T> {

boolean isApplicable(BeanCreationDirective directive);

T create(BeanCreationDirective directive);
boolean isApplicable(BeanCreationDirective directive);

T create(BeanCreationDirective directive);
}
Expand Up @@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.dozer;
package com.github.dozermapper.core;

/**
* Public custom converter interface.
Expand All @@ -27,8 +27,6 @@
* <a
* href="https://dozermapper.github.io/gitbook/documentation/customconverter.html">
* https://dozermapper.github.io/gitbook/documentation/customconverter.html</a>
*
* @author johnsen.knut-erik
*/
public interface ConfigurableCustomConverter extends CustomConverter {

Expand Down
Expand Up @@ -13,28 +13,22 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.dozer;
package com.github.dozermapper.core;

/**
* Public custom converter interface.
*
* <p>
* In the Dozer mapping file(s), you can add some XML to tell Dozer to use a custom converter for certain class A and
* class B types. When a custom converter is specified for a class A and class B combination, Dozer will invoke the
* custom converter to perform the data mapping instead of the standard mapping logic.
*
* <p>
* <p>
* <a
* href="https://dozermapper.github.io/gitbook/documentation/customconverter.html">
* https://dozermapper.github.io/gitbook/documentation/customconverter.html</a>
*
*
* @author sullins.ben
* @author garsombke.franz
* @author tierney.matt
*
*/
public interface CustomConverter {

Object convert(Object existingDestinationFieldValue, Object sourceFieldValue, Class<?> destinationClass, Class<?> sourceClass);
Object convert(Object existingDestinationFieldValue, Object sourceFieldValue, Class<?> destinationClass, Class<?> sourceClass);

}
Expand Up @@ -13,24 +13,22 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.dozer;
package com.github.dozermapper.core;

import org.dozer.classmap.ClassMap;
import org.dozer.fieldmap.FieldMap;
import com.github.dozermapper.core.classmap.ClassMap;
import com.github.dozermapper.core.fieldmap.FieldMap;

/**
* Public custom field mapper interface. A custom field mapper should only be used in very rare and unusual cases
* because it is invoked for ALL field mappings. For custom mappings of particular fields, using a CustomConverter is a
* much better choice.
*
* <p>
* <p>
* If a custom field mapper is specified, Dozer will invoke this class when performing all field mappings. If false is
* returned from the call to mapField(), then the field will be subsequently mapped by Dozer as normal.
*
* @author Gerard Toonstra
*/
public interface CustomFieldMapper {

boolean mapField(Object source, Object destination, Object sourceFieldValue, ClassMap classMap, FieldMap fieldMapping);
boolean mapField(Object source, Object destination, Object sourceFieldValue, ClassMap classMap, FieldMap fieldMapping);

}

0 comments on commit c0de047

Please sign in to comment.