@Override
    protected final void buildSpecific( TypeSpec.Builder typeBuilder ) throws UnableToCompleteException, UnsupportedTypeException {

        if ( beanInfo.getBuilder().isPresent() || beanInfo.getCreatorMethod().isPresent() ) {
            typeBuilder.addMethod( buildInitInstanceBuilderMethod() );
        }

        // no need to generate properties for non instantiable class
        if ( (beanInfo.getCreatorMethod().isPresent() && !beanInfo.isCreatorDelegation()) &&
                (!properties.isEmpty() || beanInfo
                        .getAnySetterPropertyInfo().isPresent()) ) {
            buildInitPropertiesMethods( typeBuilder );
        }

        if ( beanInfo.getIdentityInfo().isPresent() ) {
            try {
                typeBuilder.addMethod( buildInitIdentityInfoMethod( beanInfo.getIdentityInfo().get() ) );
            } catch ( UnsupportedTypeException e ) {
                logger.log( Type.WARN, "Identity type is not supported. We ignore it." );
            }
        }

        if ( beanInfo.getTypeInfo().isPresent() ) {
            typeBuilder.addMethod( buildInitTypeInfoMethod( beanInfo.getTypeInfo().get() ) );
        }

        ImmutableList<JClassType> subtypes = filterSubtypes();
        if ( !subtypes.isEmpty() ) {
            typeBuilder.addMethod( buildInitMapSubtypeClassToDeserializerMethod( subtypes ) );
        }

        if ( beanInfo.isIgnoreUnknown() ) {
            typeBuilder.addMethod( buildIsDefaultIgnoreUnknownMethod() );
        }
    }
@ Override protected final void buildSpecific ( TypeSpec . Builder typeBuilder ) throws UnableToCompleteException , UnsupportedTypeException { if ( beanInfo . getBuilder ( ) . isPresent ( ) || beanInfo . getCreatorMethod ( ) . isPresent ( ) ) { typeBuilder . addMethod ( buildInitInstanceBuilderMethod ( ) ) ; } if ( ( beanInfo . getCreatorMethod ( ) . isPresent ( ) && ! beanInfo . isCreatorDelegation ( ) ) && ( ! properties . isEmpty ( ) || beanInfo . getAnySetterPropertyInfo ( ) . isPresent ( ) ) ) { buildInitPropertiesMethods ( typeBuilder ) ; } if ( beanInfo . getIdentityInfo ( ) . isPresent ( ) ) { try { typeBuilder . addMethod ( buildInitIdentityInfoMethod ( beanInfo . getIdentityInfo ( ) . get ( ) ) ) ; } catch ( UnsupportedTypeException e ) { logger . log ( Type . WARN , "Identity type is not supported. We ignore it." ) ; } } if ( beanInfo . getTypeInfo ( ) . isPresent ( ) ) { typeBuilder . addMethod ( buildInitTypeInfoMethod ( beanInfo . getTypeInfo ( ) . get ( ) ) ) ; } ImmutableList < JClassType > subtypes = filterSubtypes ( ) ; if ( ! subtypes . isEmpty ( ) ) { typeBuilder . addMethod ( buildInitMapSubtypeClassToDeserializerMethod ( subtypes ) ) ; } if ( beanInfo . isIgnoreUnknown ( ) ) { typeBuilder . addMethod ( buildIsDefaultIgnoreUnknownMethod ( ) ) ; } }
{@inheritDoc}