OneToOneAttributeSourceImpl(
      MappingDocument sourceMappingDocument,
      AttributeSourceContainer container,
      final JaxbOneToOneElement oneToOneElement,
      final String logicalTableName,
      NaturalIdMutability naturalIdMutability) {
    super(sourceMappingDocument, naturalIdMutability, oneToOneElement.getPropertyRef());
    this.oneToOneElement = oneToOneElement;
    this.containingTableName = logicalTableName;
    this.valueSources =
        Helper.buildValueSources(
            sourceMappingDocument(),
            new Helper.ValueSourcesAdapter() {
              @Override
              public String getColumnAttribute() {
                // Not applicable to one-to-one
                return null;
              }

              @Override
              public String getFormulaAttribute() {
                return oneToOneElement.getFormulaAttribute();
              }

              @Override
              public List<JaxbColumnElement> getColumn() {
                // Not applicable to one-to-one
                return null;
              }

              @Override
              public List<String> getFormula() {
                return oneToOneElement.getFormula();
              }

              @Override
              public String getContainingTableName() {
                return logicalTableName;
              }

              @Override
              public boolean isIncludedInInsertByDefault() {
                return true;
              }

              @Override
              public boolean isIncludedInUpdateByDefault() {
                return false;
              }
            });

    this.attributeRole = container.getAttributeRoleBase().append(oneToOneElement.getName());
    this.attributePath = container.getAttributePathBase().append(oneToOneElement.getName());
  }
 @Override
 public String getName() {
   return oneToOneElement.getName();
 }