public static Builder builder(final Resource r) {
        return builder(r.getIdentifier()).interactionModel(r.getInteractionModel())
                        .container(r.getContainer().orElse(null))
                        .memberRelation(r.getMemberRelation().orElse(null))
                        .membershipResource(r.getMembershipResource().orElse(null))
                        .memberOfRelation(r.getMemberOfRelation().orElse(null))
                        .insertedContentRelation(r.getInsertedContentRelation().orElse(null));
    }
public static Builder builder ( final Resource r ) { return builder ( r . getIdentifier ( ) ) . interactionModel ( r . getInteractionModel ( ) ) . container ( r . getContainer ( ) . orElse ( null ) ) . memberRelation ( r . getMemberRelation ( ) . orElse ( null ) ) . membershipResource ( r . getMembershipResource ( ) . orElse ( null ) ) . memberOfRelation ( r . getMemberOfRelation ( ) . orElse ( null ) ) . insertedContentRelation ( r . getInsertedContentRelation ( ) . orElse ( null ) ) ; }
A mutable builder for a {@link Metadata} object.

@param r the resource
@return a builder for a {@link Metadata} object