Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Default Boolean elements to 'false' #137

Closed
stansmith907 opened this issue Mar 17, 2017 · 0 comments
Closed

Default Boolean elements to 'false' #137

stansmith907 opened this issue Mar 17, 2017 · 0 comments
Labels
Milestone

Comments

@stansmith907
Copy link
Contributor

The mdTranslator defaults all Boolean elements to 'false' - with one exception. This should be reflected in the schema to improve documentation. See the list of internal object Boolean elements below...

The following elements have default = false

    def newContact
        intObj = {
            contactId: nil,
            isOrganization: false,
            name: nil,
            positionName: nil,
            memberOfOrgs: [],
            logos: [],
            phones: [],
            addresses: [],
            eMailList: [],
            onlineResources: [],
            hoursOfService: [],
            contactInstructions: nil,
            contactType: nil
        }
    end
    def newDataDictionary
        intObj = {
            citation: {},
            subjects: [],
            recommendedUses: [],
            locales: [],
            responsibleParty: {},
            dictionaryFormat: nil,
            includedWithDataset: false,
            domains: [],
            entities: []
        }
    end
    def newEntityIndex
        intObj = {
            indexCode: nil,
            duplicate: false,
            attributeNames: []
        }
    end
    def newEntityAttribute
        intObj = {
            attributeName: nil,
            attributeCode: nil,
            attributeAlias: [],
            attributeDefinition: nil,
            dataType: nil,
            allowNull: false,
            allowMany: false,
            unitOfMeasure: nil,
            domainId: nil,
            minValue: nil,
            maxValue: nil
        }
    end
    def newGridInfo
        intObj = {
            numberOfDimensions: nil,
            dimension: [],
            cellGeometry: nil,
            transformationParameterAvailable: false
        }
    end
    def newGeorectifiedInfo
        intObj = {
            gridRepresentation: {},
            checkPointAvailable: false,
            checkPointDescription: nil,
            cornerPoints: [],
            centerPoint: [],
            pointInPixel: nil,
            transformationDimensionDescription: nil,
            transformationDimensionMapping: nil
        }
    end
    def newGeoreferenceableInfo
        intObj = {
            gridRepresentation: {},
            controlPointAvailable: false,
            orientationParameterAvailable: false,
            orientationParameterDescription: nil,
            georeferencedParameter: nil,
            parameterCitation: []
        }
    end
    def newImageDescription
        intObj = {
            illuminationElevationAngle: nil,
            illuminationAzimuthAngle: nil,
            imagingCondition: nil,
            imageQualityCode: {},
            cloudCoverPercent: nil,
            compressionQuantity: nil,
            triangulationIndicator: false,
            radiometricCalibrationAvailable: false,
            cameraCalibrationAvailable: false,
            filmDistortionAvailable: false,
            lensDistortionAvailable: false
        }
    end
    def newAllocation
        intObj = {
            amount: nil,
            currency: nil,
            sourceId: nil,
            recipientId: nil,
            matching: false,
            comment: nil
        }
    end

The following element has default = true

    def newGeographicExtent
        intObj = {
            containsData: true,
            identifier: {},
            boundingBox: {},
            geographicElement: []
        }
    end
@stansmith907 stansmith907 added this to the 2.0.2 milestone Mar 17, 2017
@jlblcc jlblcc closed this as completed in 15c8a01 Mar 21, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant