{"size": 1672, "ext": "js", "max_stars_repo_path": "packages/defaults/src/definitions.js", "max_stars_repo_name": "FadySalama/thingweb-playground", "max_stars_repo_stars_event_min_datetime": null, "max_stars_repo_stars_event_max_datetime": null, "max_issues_repo_path": "packages/defaults/src/definitions.js", "max_issues_repo_name": "FadySalama/thingweb-playground", "max_issues_repo_issues_event_min_datetime": null, "max_issues_repo_issues_event_max_datetime": null, "max_forks_repo_path": "packages/defaults/src/definitions.js", "max_forks_repo_name": "FadySalama/thingweb-playground", "max_forks_repo_forks_event_min_datetime": null, "max_forks_repo_forks_event_max_datetime": null}
{"max_stars_count": null, "max_issues_count": null, "max_forks_count": null, "avg_line_length": 24.9552238806, "max_line_length": 92, "alphanum_fraction": 0.6315789474}
/**
 * the TD default value definitions according to
 * https://www.w3.org/TR/2020/REC-wot-thing-description-20200409/
 *
 * represented with:
 * class[-superClass] -> property -> value
 */
const defaultLookup = {
    Form: {
        contentType: "application/json"
    },
    "Form-PropertyAffordance": {
        op: ["readproperty", "writeproperty"]
    },
    "Form-ActionAffordance": {
        op: "invokeaction"
    },
    "Form-EventAffordance": {
        op: "subscribeevent" // will be ["subscribeevent", "unsubscribeevent"] in the future
    },
    DataSchema: {
        readOnly: false,
        writeOnly: false
    },
    PropertyAffordance: {
        observable: false
    },
    ActionAffordance: {
        safe: false,
        idempotent: false
    },
    BasicSecuritySchema: {
        in: "header"
    },
    DigestSecurityScheme: {
        in: "header",
        qop: "auth"
    },
    BearerSecurityScheme: {
        in: "header",
        alg: "ES256",
        format: "jwt"
    },
    APIKeySecurityScheme: {
        in: "query"
    }
}

/**
 * The possible types of objects to extend
 */
const defaultClasses = {
    form: "Form",
    formPropertyAffordance: "Form-PropertyAffordance",
    formActionAffordance: "Form-ActionAffordance",
    formEventAffordance: "Form-EventAffordance",
    dataSchema: "DataSchema",
    propertyAffordance: "PropertyAffordance",
    actionAffordance: "ActionAffordance",
    basicSecuritySchema: "BasicSecuritySchema",
    digestSecurityScheme: "DigestSecurityScheme",
    bearerSecurityScheme: "BearerSecurityScheme",
    apiKeySecurityScheme: "APIKeySecurityScheme"
}

module.exports = {defaultLookup, defaultClasses}
