text:
FOUR.WalkController = (function () {

    /**
     * First person navigation controller. Uses keys to control movement in
     * cardinal directions. Assumes that +Z is up. Accepts a function that
     * maintains a minimum Z position.
     */
    function WalkController(config) {
        THREE.EventDispatcher.call(this);
        config = config || {};
        var self = this;

        self.KEY = {
            CANCEL: FOUR.KEY.ESC,
            CTRL: FOUR.KEY.CTRL,
            MOVE_TO_EYE_HEIGHT: FOUR.KEY.GRAVE_ACCENT,
            MOVE_FORWARD: FOUR.KEY.ARROW_UP,
            MOVE_LEFT: FOUR.KEY.ARROW_LEFT,
            MOVE_BACK: FOUR.KEY.ARROW_DOWN,
            MOVE_RIGHT: FOUR.KEY.ARROW_RIGHT,
            MOVE_UP: -1,
            MOVE_DOWN: -1,
            ROTATE_LEFT: -1,
            ROTATE_RIGHT: -1
        };
        self.MOUSE_STATE = {
            DOWN: 0,
            UP: 1
        };

        self.camera = config.camera || config.viewport.camera;
        self.domElement = config.domElement || config.viewport.domElement;
        self.enabled = false;
        self.enforceWalkHeight = true;
        self.listeners = {};
        self.lookChange = false;
        self.lookSpeed = 0.85;
        self.modifiers = {
            'ALT': false,
            'CTRL': false,
            'SHIFT': false
        };
        self.mouse = {
            direction: new THREE.Vector2(),
            end: {x: 0, y: 0},
            start: {x: 0, y: 0},
            state: self.MOUSE_STATE.UP
        };
        self.move = {
            forward: false,
            backward: false,
            left: false,
            right: false,
            up: false,
            down: false
        };
        self.movementSpeed = 100.0;
        self.raycaster = new THREE.Raycaster();
        self.timeout = null;
        self.viewport = config.viewport;
        self.walkHeight = null;

        self.viewHalfX = self.domElement.offsetWidth / 2;
        self.viewHalfY = self.domElement.offsetHeight / 2;

        self.domElement.setAttribute('tabindex', -1);

        // done
        Object.keys(config).forEach(function (key) {
            self[key] = config[key];
        });
    }

    WalkController.prototype = Object.create(THREE.EventDispatcher.prototype);

    WalkController.prototype.constructor = WalkController;

    WalkController.prototype.WALK_HEIGHT = 2;

    WalkController.prototype.contextMenu = function (event) {
        event.preventDefault();
    };

    WalkController.prototype.disable = function () {
        var self = this;
        self.enabled = false;
        Object.keys(self.listeners).forEach(function (key) {
            var listener = self.listeners[key];
            listener.element.removeEventListener(listener.event, listener.fn);
            delete self.listeners[key];
        });
    };

    WalkController.prototype.enable = function () {
        var self = this;
        // clear all listeners to ensure that we can never add multiple listeners
        // for the same events
        self.disable();
        function addListener(element, event, fn) {
            if (!self.listeners[event]) {
                self.listeners[event] = {
                    element: element,
                    event: event,
                    fn: fn.bind(self)
                };
                element.addEventListener(event, self.listeners[event].fn, false);
            }
        }

        addListener(window, 'keydown', self.onKeyDown);
        addListener(window, 'keyup', self.onKeyUp);
        self.enabled = true;
        self.setWalkHeight();
    };

    /**
     * Get the walking height at the specified position.
     * @param {THREE.Vector3} position Camera position
     * @returns {THREE.Vector3} Position
     */
    WalkController.prototype.getWalkHeight = function (position) {
        return 0 + this.WALK_HEIGHT;
    };

    WalkController.prototype.onKeyDown = function (event) {
        var self = this;
        if (!self.enabled) {
            return;
        }
        switch (event.keyCode) {
            case FOUR.KEY.CTRL:
                self.modifiers[FOUR.KEY.CTRL] = true;
                break;
            case self.KEY.MOVE_TO_EYE_HEIGHT:
                self.setWalkHeight();
                self.dispatchEvent({type: FOUR.EVENT.CONTINUOUS_UPDATE_START});
                break;
            case self.KEY.MOVE_FORWARD:
                self.move.forward = true;
                self.dispatchEvent({type: FOUR.EVENT.CONTINUOUS_UPDATE_START});
                break;
            case self.KEY.MOVE_BACK:
                self.move.backward = true;
                self.dispatchEvent({type: FOUR.EVENT.CONTINUOUS_UPDATE_START});
                break;
            case self.KEY.MOVE_LEFT:
                self.move.left = true;
                self.dispatchEvent({type: FOUR.EVENT.CONTINUOUS_UPDATE_START});
                break;
            case self.KEY.MOVE_RIGHT:
                self.move.right = true;
                self.dispatchEvent({type: FOUR.EVENT.CONTINUOUS_UPDATE_START});
                break;
            case self.KEY.MOVE_UP:
                self.move.up = true;
                self.dispatchEvent({type: FOUR.EVENT.CONTINUOUS_UPDATE_START});
                break;
            case self.KEY.MOVE_DOWN:
                self.move.down = true;
                self.dispatchEvent({type: FOUR.EVENT.CONTINUOUS_UPDATE_START});
                break;
        }
    };

    WalkController.prototype.onKeyUp = function (event) {
        var self = this;
        switch (event.keyCode) {
            case FOUR.KEY.CTRL:
                self.modifiers[FOUR.KEY.CTRL] = false;
                break;
            case self.KEY.MOVE_FORWARD:
                self.move.forward = false;
                self.dispatchEvent({type: FOUR.EVENT.CONTINUOUS_UPDATE_END});
                break;
            case self.KEY.MOVE_BACK:
                self.move.backward = false;
                self.dispatchEvent({type: FOUR.EVENT.CONTINUOUS_UPDATE_END});
                break;
            case self.KEY.MOVE_LEFT:
                self.move.left = false;
                self.dispatchEvent({type: FOUR.EVENT.CONTINUOUS_UPDATE_END});
                break;
            case self.KEY.MOVE_RIGHT:
                self.move.right = false;
                self.dispatchEvent({type: FOUR.EVENT.CONTINUOUS_UPDATE_END});
                break;
            case self.KEY.MOVE_UP:
                self.move.up = false;
                self.dispatchEvent({type: FOUR.EVENT.CONTINUOUS_UPDATE_END});
                break;
            case self.KEY.MOVE_DOWN:
                self.move.down = false;
                self.dispatchEvent({type: FOUR.EVENT.CONTINUOUS_UPDATE_END});
                break;
            case FOUR.KEY.CANCEL:
                Object.keys(self.move).forEach(function (key) {
                    self.move[key] = false;
                });
                self.lookChange = false;
                self.dispatchEvent({type: FOUR.EVENT.CONTINUOUS_UPDATE_END});
                break;
        }
    };

    WalkController.prototype.setWalkHeight = function () {
        var self = this;
        var pos = new THREE.Vector3(
            self.camera.position.x,
            self.camera.position.y,
            self.WALK_HEIGHT
        );
        var target = new THREE.Vector3(
            self.camera.target.x,
            self.camera.target.y,
            self.WALK_HEIGHT
        );
        return self.camera
            .resetOrientation(true)
            .then(function () {
                return self.camera.setPositionAndTarget(pos, target);
            });
    };

    WalkController.prototype.update = function (delta) {
        var change = false, cross, distance, height, next, offset, self = this;
        if (!self.enabled) {
            return;
        }
        distance = delta * self.movementSpeed;
        offset = new THREE.Vector3().subVectors(self.camera.position, self.camera.target);
        offset.setLength(distance);
        cross = new THREE.Vector3().crossVectors(offset, self.camera.up);

        // translate the camera
        if (self.move.forward) {
            offset.negate();
            next = new THREE.Vector3().addVectors(self.camera.position, offset);
            self.camera.position.copy(next);
            next = new THREE.Vector3().addVectors(self.camera.target, offset);
            self.camera.target.copy(next);
            change = true;
        }
        if (self.move.backward) {
            next = new THREE.Vector3().addVectors(self.camera.position, offset);
            self.camera.position.copy(next);
            next = new THREE.Vector3().addVectors(self.camera.target, offset);
            self.camera.target.copy(next);
            change = true;
        }
        if (self.move.right) {
            cross.negate();
            next = new THREE.Vector3().addVectors(self.camera.position, cross);
            self.camera.position.copy(next);
            next = new THREE.Vector3().addVectors(self.camera.target, cross);
            self.camera.target.copy(next);
            change = true;
        }
        if (self.move.left) {
            next = new THREE.Vector3().addVectors(self.camera.position, cross);
            self.camera.position.copy(next);
            next = new THREE.Vector3().addVectors(self.camera.target, cross);
            self.camera.target.copy(next);
            change = true;
        }
        if (self.move.up) {
            offset = new THREE.Vector3().copy(self.camera.up);
            offset.setLength(distance);
            next = new THREE.Vector3().addVectors(self.camera.position, offset);
            self.camera.position.copy(next);
            next = new THREE.Vector3().addVectors(self.camera.target, offset);
            self.camera.target.copy(next);
            change = true;
        }
        if (self.move.down) {
            height = self.getWalkHeight(self.camera.position);
            offset = new THREE.Vector3().copy(self.camera.up).negate();
            offset.setLength(distance);
            next = new THREE.Vector3().addVectors(self.camera.position, offset);
            next.z = next.z < height ? height : next.z;
            self.camera.position.copy(next);
            next = new THREE.Vector3().addVectors(self.camera.target, offset);
            next.z = next.z < height ? height : next.z;
            self.camera.target.copy(next);
            change = true;
        }

        if (change) {
            self.dispatchEvent({type: FOUR.EVENT.RENDER});
        }
    };

    return WalkController;

}());


text:
FOUNDATION_EXPORT double TycoonKitVersionNumber;

//! Project version string for TycoonKit.
FOUNDATION_EXPORT const unsigned char TycoonKitVersionString[];

// In this header, you should import all the public headers of your framework using statements like #import <TycoonKit/PublicHeader.h>

redpajama_set_name: RedPajamaGithub


text:
/*global define*/
define([
        '../Core/BoxGeometry',
        '../Core/BoxOutlineGeometry',
        '../Core/Color',
        '../Core/ColorGeometryInstanceAttribute',
        '../Core/defaultValue',
        '../Core/defined',
        '../Core/defineProperties',
        '../Core/destroyObject',
        '../Core/DeveloperError',
        '../Core/Event',
        '../Core/GeometryInstance',
        '../Core/Iso8601',
        '../Core/ShowGeometryInstanceAttribute',
        '../Scene/MaterialAppearance',
        '../Scene/PerInstanceColorAppearance',
        '../Scene/Primitive',
        './ColorMaterialProperty',
        './ConstantProperty',
        './dynamicGeometryGetBoundingSphere',
        './MaterialProperty',
        './Property'
    ], function(
        BoxGeometry,
        BoxOutlineGeometry,
        Color,
        ColorGeometryInstanceAttribute,
        defaultValue,
        defined,
        defineProperties,
        destroyObject,
        DeveloperError,
        Event,
        GeometryInstance,
        Iso8601,
        ShowGeometryInstanceAttribute,
        MaterialAppearance,
        PerInstanceColorAppearance,
        Primitive,
        ColorMaterialProperty,
        ConstantProperty,
        dynamicGeometryGetBoundingSphere,
        MaterialProperty,
        Property) {
    "use strict";

    var defaultMaterial = new ColorMaterialProperty(Color.WHITE);
    var defaultShow = new ConstantProperty(true);
    var defaultFill = new ConstantProperty(true);
    var defaultOutline = new ConstantProperty(false);
    var defaultOutlineColor = new ConstantProperty(Color.BLACK);
    var scratchColor = new Color();

    var GeometryOptions = function(entity) {
        this.id = entity;
        this.vertexFormat = undefined;
        this.dimensions = undefined;
    };

    /**
     * A {@link GeometryUpdater} for boxes.
     * Clients do not normally create this class directly, but instead rely on {@link DataSourceDisplay}.
     * @alias BoxGeometryUpdater
     * @constructor
     *
     * @param {Entity} entity The entity containing the geometry to be visualized.
     * @param {Scene} scene The scene where visualization is taking place.
     */
    var BoxGeometryUpdater = function(entity, scene) {
        //>>includeStart('debug', pragmas.debug);
        if (!defined(entity)) {
            throw new DeveloperError('entity is required');
        }
        if (!defined(scene)) {
            throw new DeveloperError('scene is required');
        }
        //>>includeEnd('debug');

        this._entity = entity;
        this._scene = scene;
        this._entitySubscription = entity.definitionChanged.addEventListener(BoxGeometryUpdater.prototype._onEntityPropertyChanged, this);
        this._fillEnabled = false;
        this._dynamic = false;
        this._outlineEnabled = false;
        this._geometryChanged = new Event();
        this._showProperty = undefined;
        this._materialProperty = undefined;
        this._hasConstantOutline = true;
        this._showOutlineProperty = undefined;
        this._outlineColorProperty = undefined;
        this._outlineWidth = 1.0;
        this._options = new GeometryOptions(entity);
        this._onEntityPropertyChanged(entity, 'box', entity.box, undefined);
    };

    defineProperties(BoxGeometryUpdater, {
        /**
         * Gets the type of Appearance to use for simple color-based geometry.
         * @memberof BoxGeometryUpdater
         * @type {Appearance}
         */
        perInstanceColorAppearanceType : {
            value : PerInstanceColorAppearance
        },
        /**
         * Gets the type of Appearance to use for material-based geometry.
         * @memberof BoxGeometryUpdater
         * @type {Appearance}
         */
        materialAppearanceType : {
            value : MaterialAppearance
        }
    });

    defineProperties(BoxGeometryUpdater.prototype, {
        /**
         * Gets the entity associated with this geometry.
         * @memberof BoxGeometryUpdater.prototype
         *
         * @type {Entity}
         * @readonly
         */
        entity : {
            get : function() {
                return this._entity;
            }
        },
        /**
         * Gets a value indicating if the geometry has a fill component.
         * @memberof BoxGeometryUpdater.prototype
         *
         * @type {Boolean}
         * @readonly
         */
        fillEnabled : {
            get : function() {
                return this._fillEnabled;
            }
        },
        /**
         * Gets a value indicating if fill visibility varies with simulation time.
         * @memberof BoxGeometryUpdater.prototype
         *
         * @type {Boolean}
         * @readonly
         */
        hasConstantFill : {
            get : function() {
                return !this._fillEnabled ||
                       (!defined(this._entity.availability) &&
                        Property.isConstant(this._showProperty) &&
                        Property.isConstant(this._fillProperty));
            }
        },
        /**
         * Gets the material property used to fill the geometry.
         * @memberof BoxGeometryUpdater.prototype
         *
         * @type {MaterialProperty}
         * @readonly
         */
        fillMaterialProperty : {
            get : function() {
                return this._materialProperty;
            }
        },
        /**
         * Gets a value indicating if the geometry has an outline component.
         * @memberof BoxGeometryUpdater.prototype
         *
         * @type {Boolean}
         * @readonly
         */
        outlineEnabled : {
            get : function() {
                return this._outlineEnabled;
            }
        },
        /**
         * Gets a value indicating if the geometry has an outline component.
         * @memberof BoxGeometryUpdater.prototype
         *
         * @type {Boolean}
         * @readonly
         */
        hasConstantOutline : {
            get : function() {
                return !this._outlineEnabled ||
                       (!defined(this._entity.availability) &&
                        Property.isConstant(this._showProperty) &&
                        Property.isConstant(this._showOutlineProperty));
            }
        },
        /**
         * Gets the {@link Color} property for the geometry outline.
         * @memberof BoxGeometryUpdater.prototype
         *
         * @type {Property}
         * @readonly
         */
        outlineColorProperty : {
            get : function() {
                return this._outlineColorProperty;
            }
        },
        /**
         * Gets the constant with of the geometry outline, in pixels.
         * This value is only valid if isDynamic is false.
         * @memberof BoxGeometryUpdater.prototype
         *
         * @type {Number}
         * @readonly
         */
        outlineWidth : {
            get : function() {
                return this._outlineWidth;
            }
        },
        /**
         * Gets a value indicating if the geometry is time-varying.
         * If true, all visualization is delegated to the {@link DynamicGeometryUpdater}
         * returned by GeometryUpdater#createDynamicUpdater.
         * @memberof BoxGeometryUpdater.prototype
         *
         * @type {Boolean}
         * @readonly
         */
        isDynamic : {
            get : function() {
                return this._dynamic;
            }
        },
        /**
         * Gets a value indicating if the geometry is closed.
         * This property is only valid for static geometry.
         * @memberof BoxGeometryUpdater.prototype
         *
         * @type {Boolean}
         * @readonly
         */
        isClosed : {
            value : true
        },
        /**
         * Gets an event that is raised whenever the public properties
         * of this updater change.
         * @memberof BoxGeometryUpdater.prototype
         *
         * @type {Boolean}
         * @readonly
         */
        geometryChanged : {
            get : function() {
                return this._geometryChanged;
            }
        }
    });

    /**
     * Checks if the geometry is outlined at the provided time.
     *
     * @param {JulianDate} time The time for which to retrieve visibility.
     * @returns {Boolean} true if geometry is outlined at the provided time, false otherwise.
     */
    BoxGeometryUpdater.prototype.isOutlineVisible = function(time) {
        var entity = this._entity;
        return this._outlineEnabled && entity.isAvailable(time) && this._showProperty.getValue(time) && this._showOutlineProperty.getValue(time);
    };

    /**
     * Checks if the geometry is filled at the provided time.
     *
     * @param {JulianDate} time The time for which to retrieve visibility.
     * @returns {Boolean} true if geometry is filled at the provided time, false otherwise.
     */
    BoxGeometryUpdater.prototype.isFilled = function(time) {
        var entity = this._entity;
        return this._fillEnabled && entity.isAvailable(time) && this._showProperty.getValue(time) && this._fillProperty.getValue(time);
    };

    /**
     * Creates the geometry instance which represents the fill of the geometry.
     *
     * @param {JulianDate} time The time to use when retrieving initial attribute values.
     * @returns {GeometryInstance} The geometry instance representing the filled portion of the geometry.
     *
     * @exception {DeveloperError} This instance does not represent a filled geometry.
     */
    BoxGeometryUpdater.prototype.createFillGeometryInstance = function(time) {
        //>>includeStart('debug', pragmas.debug);
        if (!defined(time)) {
            throw new DeveloperError('time is required.');
        }

        if (!this._fillEnabled) {
            throw new DeveloperError('This instance does not represent a filled geometry.');
        }
        //>>includeEnd('debug');

        var entity = this._entity;
        var isAvailable = entity.isAvailable(time);

        var attributes;

        var color;
        var show = new ShowGeometryInstanceAttribute(isAvailable && entity.isShowing && this._showProperty.getValue(time) && this._fillProperty.getValue(time));
        if (this._materialProperty instanceof ColorMaterialProperty) {
            var currentColor = Color.WHITE;
            if (defined(this._materialProperty.color) && (this._materialProperty.color.isConstant || isAvailable)) {
                currentColor = this._materialProperty.color.getValue(time);
            }
            color = ColorGeometryInstanceAttribute.fromColor(currentColor);
            attributes = {
                show : show,
                color : color
            };
        } else {
            attributes = {
                show : show
            };
        }

        return new GeometryInstance({
            id : entity,
            geometry : BoxGeometry.fromDimensions(this._options),
            modelMatrix : entity._getModelMatrix(Iso8601.MINIMUM_VALUE),
            attributes : attributes
        });
    };

    /**
     * Creates the geometry instance which represents the outline of the geometry.
     *
     * @param {JulianDate} time The time to use when retrieving initial attribute values.
     * @returns {GeometryInstance} The geometry instance representing the outline portion of the geometry.
     *
     * @exception {DeveloperError} This instance does not represent an outlined geometry.
     */
    BoxGeometryUpdater.prototype.createOutlineGeometryInstance = function(time) {
        //>>includeStart('debug', pragmas.debug);
        if (!defined(time)) {
            throw new DeveloperError('time is required.');
        }

        if (!this._outlineEnabled) {
            throw new DeveloperError('This instance does not represent an outlined geometry.');
        }
        //>>includeEnd('debug');

        var entity = this._entity;
        var isAvailable = entity.isAvailable(time);
        var outlineColor = Property.getValueOrDefault(this._outlineColorProperty, time, Color.BLACK);

        return new GeometryInstance({
            id : entity,
            geometry : BoxOutlineGeometry.fromDimensions(this._options),
            modelMatrix : entity._getModelMatrix(Iso8601.MINIMUM_VALUE),
            attributes : {
                show : new ShowGeometryInstanceAttribute(isAvailable && entity.isShowing && this._showProperty.getValue(time) && this._showOutlineProperty.getValue(time)),
                color : ColorGeometryInstanceAttribute.fromColor(outlineColor)
            }
        });
    };

    /**
     * Returns true if this object was destroyed; otherwise, false.
     *
     * @returns {Boolean} True if this object was destroyed; otherwise, false.
     */
    BoxGeometryUpdater.prototype.isDestroyed = function() {
        return false;
    };

    /**
     * Destroys and resources used by the object.  Once an object is destroyed, it should not be used.
     *
     * @exception {DeveloperError} This object was destroyed, i.e., destroy() was called.
     */
    BoxGeometryUpdater.prototype.destroy = function() {
        this._entitySubscription();
        destroyObject(this);
    };

    BoxGeometryUpdater.prototype._onEntityPropertyChanged = function(entity, propertyName, newValue, oldValue) {
        if (!(propertyName === 'availability' || propertyName === 'position' || propertyName === 'orientation' || propertyName === 'box')) {
            return;
        }

        var box = this._entity.box;

        if (!defined(box)) {
            if (this._fillEnabled || this._outlineEnabled) {
                this._fillEnabled = false;
                this._outlineEnabled = false;
                this._geometryChanged.raiseEvent(this);
            }
            return;
        }

        var fillProperty = box.fill;
        var fillEnabled = defined(fillProperty) && fillProperty.isConstant ? fillProperty.getValue(Iso8601.MINIMUM_VALUE) : true;

        var outlineProperty = box.outline;
        var outlineEnabled = defined(outlineProperty);
        if (outlineEnabled && outlineProperty.isConstant) {
            outlineEnabled = outlineProperty.getValue(Iso8601.MINIMUM_VALUE);
        }

        if (!fillEnabled && !outlineEnabled) {
            if (this._fillEnabled || this._outlineEnabled) {
                this._fillEnabled = false;
                this._outlineEnabled = false;
                this._geometryChanged.raiseEvent(this);
            }
            return;
        }

        var dimensions = box.dimensions;
        var position = entity.position;

        var show = box.show;
        if (!defined(dimensions) || !defined(position) || (defined(show) && show.isConstant && !show.getValue(Iso8601.MINIMUM_VALUE))) {
            if (this._fillEnabled || this._outlineEnabled) {
                this._fillEnabled = false;
                this._outlineEnabled = false;
                this._geometryChanged.raiseEvent(this);
            }
            return;
        }

        var material = defaultValue(box.material, defaultMaterial);
        var isColorMaterial = material instanceof ColorMaterialProperty;
        this._materialProperty = material;
        this._fillProperty = defaultValue(fillProperty, defaultFill);
        this._showProperty = defaultValue(show, defaultShow);
        this._showOutlineProperty = defaultValue(box.outline, defaultOutline);
        this._outlineColorProperty = outlineEnabled ? defaultValue(box.outlineColor, defaultOutlineColor) : undefined;

        var outlineWidth = box.outlineWidth;

        this._fillEnabled = fillEnabled;
        this._outlineEnabled = outlineEnabled;

        if (!position.isConstant || //
            !Property.isConstant(entity.orientation) || //
            !dimensions.isConstant || //
            !Property.isConstant(outlineWidth)) {
            if (!this._dynamic) {
                this._dynamic = true;
                this._geometryChanged.raiseEvent(this);
            }
        } else {
            var options = this._options;
            options.vertexFormat = isColorMaterial ? PerInstanceColorAppearance.VERTEX_FORMAT : MaterialAppearance.MaterialSupport.TEXTURED.vertexFormat;
            options.dimensions = dimensions.getValue(Iso8601.MINIMUM_VALUE, options.dimensions);
            this._outlineWidth = defined(outlineWidth) ? outlineWidth.getValue(Iso8601.MINIMUM_VALUE) : 1.0;
            this._dynamic = false;
            this._geometryChanged.raiseEvent(this);
        }
    };

    /**
     * Creates the dynamic updater to be used when GeometryUpdater#isDynamic is true.
     *
     * @param {PrimitiveCollection} primitives The primitive collection to use.
     * @returns {DynamicGeometryUpdater} The dynamic updater used to update the geometry each frame.
     *
     * @exception {DeveloperError} This instance does not represent dynamic geometry.
     */
    BoxGeometryUpdater.prototype.createDynamicUpdater = function(primitives) {
        //>>includeStart('debug', pragmas.debug);
        if (!this._dynamic) {
            throw new DeveloperError('This instance does not represent dynamic geometry.');
        }

        if (!defined(primitives)) {
            throw new DeveloperError('primitives is required.');
        }
        //>>includeEnd('debug');

        return new DynamicGeometryUpdater(primitives, this);
    };

    /**
     * @private
     */
    var DynamicGeometryUpdater = function(primitives, geometryUpdater) {
        this._primitives = primitives;
        this._primitive = undefined;
        this._outlinePrimitive = undefined;
        this._geometryUpdater = geometryUpdater;
        this._options = new GeometryOptions(geometryUpdater._entity);
    };

    DynamicGeometryUpdater.prototype.update = function(time) {
        //>>includeStart('debug', pragmas.debug);
        if (!defined(time)) {
            throw new DeveloperError('time is required.');
        }
        //>>includeEnd('debug');

        var primitives = this._primitives;
        primitives.removeAndDestroy(this._primitive);
        primitives.removeAndDestroy(this._outlinePrimitive);
        this._primitive = undefined;
        this._outlinePrimitive = undefined;

        var geometryUpdater = this._geometryUpdater;
        var entity = geometryUpdater._entity;
        var box = entity.box;
        if (!entity.isShowing || !entity.isAvailable(time) || !Property.getValueOrDefault(box.show, time, true)) {
            return;
        }

        var options = this._options;
        var modelMatrix = entity._getModelMatrix(time);
        var dimensions = Property.getValueOrUndefined(box.dimensions, time, options.dimensions);
        if (!defined(modelMatrix) || !defined(dimensions)) {
            return;
        }

        options.dimensions = dimensions;

        if (Property.getValueOrDefault(box.fill, time, true)) {
            var material = MaterialProperty.getValue(time, geometryUpdater.fillMaterialProperty, this._material);
            this._material = material;

            var appearance = new MaterialAppearance({
                material : material,
                translucent : material.isTranslucent(),
                closed : true
            });
            options.vertexFormat = appearance.vertexFormat;

            this._primitive = primitives.add(new Primitive({
                geometryInstances : new GeometryInstance({
                    id : entity,
                    geometry : BoxGeometry.fromDimensions(options),
                    modelMatrix : modelMatrix
                }),
                appearance : appearance,
                asynchronous : false
            }));
        }

        if (Property.getValueOrDefault(box.outline, time, false)) {
            options.vertexFormat = PerInstanceColorAppearance.VERTEX_FORMAT;

            var outlineColor = Property.getValueOrClonedDefault(box.outlineColor, time, Color.BLACK, scratchColor);
            var outlineWidth = Property.getValueOrDefault(box.outlineWidth, time, 1.0);
            var translucent = outlineColor.alpha !== 1.0;

            this._outlinePrimitive = primitives.add(new Primitive({
                geometryInstances : new GeometryInstance({
                    id : entity,
                    geometry : BoxOutlineGeometry.fromDimensions(options),
                    modelMatrix : modelMatrix,
                    attributes : {
                        color : ColorGeometryInstanceAttribute.fromColor(outlineColor)
                    }
                }),
                appearance : new PerInstanceColorAppearance({
                    flat : true,
                    translucent : translucent,
                    renderState : {
                        lineWidth : geometryUpdater._scene.clampLineWidth(outlineWidth)
                    }
                }),
                asynchronous : false
            }));
        }
    };

    DynamicGeometryUpdater.prototype.getBoundingSphere = function(entity, result) {
        return dynamicGeometryGetBoundingSphere(entity, this._primitive, this._outlinePrimitive, result);
    };

    DynamicGeometryUpdater.prototype.isDestroyed = function() {
        return false;
    };

    DynamicGeometryUpdater.prototype.destroy = function() {
        var primitives = this._primitives;
        primitives.removeAndDestroy(this._primitive);
        primitives.removeAndDestroy(this._outlinePrimitive);
        destroyObject(this);
    };

    return BoxGeometryUpdater;
});


text:
var promise = require('when');
var nodefn = require('when/node/function');
var config = require('cabrel-config')();
var stockpile = require('cabrel-stockpile');
var crypto_wrapper = require('cabrel-crypto-wrapper');
var Proto = require('uberproto');

var internals = {
  client: config.buildRedisClient()
};

var Uuid = require('node-uuid');

var Scheme = Proto.extend({
  /**
   * [init description]
   *
   * @param  {[type]} server  [description]
   * @param  {[type]} options [description]
   *
   * @return {[type]}         [description]
   */
  init: function init(server, options) {
    this.server = server;

    this.options = options;
  },

  /**
   * [fetchSession description]
   *
   * @param  {[type]} id           [description]
   *
   * @return {[type]}              [description]
   */
  fetchSession: function fetchSession(id) {
    if (!id) {
      return promise.reject(new Error('ID undefined'));
    }

    var self = this;
    var prefix = config.config.prefix;
    var timestamp = stockpile.conversions.periods.midnight.unix();

    var maint_key = prefix + ':known_sessions:' + timestamp;
    var key = prefix + ':sessions';

    var zrank = nodefn.lift(internals.client.zrank.bind(internals.client));
    var hget = nodefn.lift(internals.client.hget.bind(internals.client));

    return zrank(maint_key, id).then(function(result) {
      if (result !== null) {
        return hget(key, id);
      } else {
        throw new Error('Session not found');
      }
    }).then(function(result) {
      return crypto_wrapper.iron.unseal(result, self.options.ironPassword);
    });
  },

  /**
   * [storeSession description]
   *
   * @param  {[type]} data         [description]
   *
   * @return {[type]}              [description]
   */
  storeSession: function storeSession(data) {
    if (!data) {
      return promise.reject(new Error('Session data required'));
    }

    var self = this;
    var prefix = config.config.prefix;
    var timestamp = stockpile.conversions.periods.midnight.unix();

    var maint_key = prefix + ':known_sessions:' + timestamp;
    var key = prefix + ':sessions';
    var id = Uuid.v4();

    data['sessionId'] = id;

    return crypto_wrapper.iron.seal(data, self.options.ironPassword).then(function(result) {
      // result is the sealed payload
      var commands = [['ZADD', maint_key, 1, id], ['HSET', key, id, result]];
      var multi = internals.client.multi(commands);

      var zadd = nodefn.lift(internals.client.zadd.bind(internals.client));
      var hset = nodefn.lift(internals.client.hset.bind(internals.client));

      return zadd(maint_key, 1, id).then(function() {
        return hset(key, id, result);
      }).then(function() {
        return id;
      });
    });
  },

  /**
   * [removeSession description]
   *
   * @param  {[type]} id [description]
   *
   * @return {[type]}    [description]
   */
  removeSession: function removeSession(id) {
    var prefix = config.config.prefix;
    var timestamp = stockpile.conversions.periods.midnight.unix();

    var maint_key = prefix + ':known_sessions:' + timestamp;
    var key = config.config.prefix + ':sessions';

    var commands = [['ZREM', maint_key, id], ['HDEL', key, id]];
    var multi = internals.client.multi(commands);
    var exec = nodefn.lift(multi.exec.bind(multi));

    return exec();
  },

  /**
   * [authenticate description]
   *
   * @param  {[type]} cookiePassword [description]
   * @param  {[type]} redirectTo     [description]
   * @param  {[type]} ironPassword   [description]
   *
   * @return {[type]}                [description]
   */
  setup: function setup() {
    /*cookiePassword, redirectTo, ironPassword*/
    var self = this;

    return {
      clearInvalid: true,
      isSecure: true,
      password: self.options.cookiePassword,
      redirectTo: self.options.redirectTo,
      validateFunc: function(session, callback) {
        if (stockpile.checks.isDefined(session.sessionId)) {
          self.fetchSession(session.sessionId, self.options.ironPassword).done(function(result) {
            if (result) {
              if (stockpile.checks.isObject(result)) {
                return callback(null, true, result);
              } else if (stockpile.checks.isString(result)) {
                return callback(null, true, JSON.parse(result));
              }
            } else {
              return callback(null, false);
            }
          }, function(error) {
            return callback(error);
          });
        } else {
          return callback(null, false);
        }
      }
    };
  },

  /**
   * [payload description]
   *
   * @param  {[type]}   request [description]
   * @param  {Function} next    [description]
   *
   * @return {[type]}           [description]
   */
  payload: function payload(request, next) {
    next();
  },

  /**
   * [response description]
   *
   * @param  {[type]}   request [description]
   * @param  {Function} next    [description]
   *
   * @return {[type]}           [description]
   */
  response: function response(request, next) {
    next();
  }
});

/**
 * [scheme description]
 *
 * @param  {[type]} server  [description]
 * @param  {[type]} options [description]
 *
 * @return {[type]}         [description]
 */
exports.scheme = function scheme(server, options) {
  return Scheme.create(server, options);
};


text:
#include "Firestore/core/src/api/settings.h"

#include "Firestore/core/src/util/hashing.h"

namespace firebase {
namespace firestore {
namespace api {

constexpr const char* Settings::DefaultHost;
constexpr bool Settings::DefaultSslEnabled;
constexpr bool Settings::DefaultPersistenceEnabled;
constexpr int64_t Settings::DefaultCacheSizeBytes;
constexpr int64_t Settings::MinimumCacheSizeBytes;

size_t Settings::Hash() const {
  return util::Hash(host_, ssl_enabled_, persistence_enabled_,
                    cache_size_bytes_);
}

bool operator==(const Settings& lhs, const Settings& rhs) {
  return lhs.host_ == rhs.host_ && lhs.ssl_enabled_ == rhs.ssl_enabled_ &&
         lhs.persistence_enabled_ == rhs.persistence_enabled_ &&
         lhs.cache_size_bytes_ == rhs.cache_size_bytes_;
}

}  // namespace api
}  // namespace firestore
}  // namespace firebase


text:
<?php

namespace Imgur\tests\Api;

use GuzzleHttp\Client as GuzzleClient;
use GuzzleHttp\Handler\MockHandler;
use GuzzleHttp\HandlerStack;
use GuzzleHttp\Psr7\Response;
use Imgur\Api\Comment;
use Imgur\Client;
use Imgur\HttpClient\HttpClient;

class CommentTest extends ApiTestCase
{
    public function testBaseReal()
    {
        $this->expectException(\Imgur\Exception\ErrorException::class);
        $this->expectExceptionMessage('Authentication required');

        $guzzleClient = new GuzzleClient(['base_uri' => 'https://api.imgur.com/3/']);
        $httpClient = new HttpClient([], $guzzleClient);
        $client = new Client(null, $httpClient);
        $comment = new Comment($client);

        $comment->comment('726305564');
    }

    public function testBaseWithResponse()
    {
        $mock = new MockHandler([
            new Response(200, ['Content-Type' => 'application/json'], json_encode([
                'data' => [
                    'id' => 726305564,
                    'image_id' => 'XVO7F',
                    'comment' => 'Scary !',
                    'author' => 'j0k3rx',
                    'author_id' => 703058,
                    'on_album' => false,
                    'album_cover' => null,
                    'ups' => 1,
                    'downs' => 0,
                    'points' => 1,
                    'datetime' => 1474399203,
                    'parent_id' => 0,
                    'deleted' => false,
                    'vote' => 'up',
                    'platform' => 'desktop',
                    'children' => [],
                ],
                'success' => true,
                'status' => 200,
            ])),
        ]);
        $handler = HandlerStack::create($mock);
        $guzzleClient = new GuzzleClient(['handler' => $handler]);

        $httpClient = new HttpClient([], $guzzleClient);
        $client = new Client(null, $httpClient);
        $comment = new Comment($client);

        $result = $comment->comment('726305564');

        $this->assertArrayHasKey('id', $result);
        $this->assertArrayHasKey('image_id', $result);
        $this->assertArrayHasKey('comment', $result);
        $this->assertArrayHasKey('author', $result);
        $this->assertArrayHasKey('author_id', $result);
        $this->assertArrayHasKey('on_album', $result);
        $this->assertArrayHasKey('album_cover', $result);
        $this->assertArrayHasKey('ups', $result);
        $this->assertArrayHasKey('downs', $result);
        $this->assertArrayHasKey('points', $result);
        $this->assertArrayHasKey('datetime', $result);
        $this->assertArrayHasKey('parent_id', $result);
        $this->assertArrayHasKey('deleted', $result);
        $this->assertArrayHasKey('vote', $result);
        $this->assertArrayHasKey('platform', $result);
        $this->assertArrayHasKey('children', $result);
    }

    public function testComment()
    {
        $expectedValue = [
            'data' => [
                'id' => '726305564',
            ],
            'success' => true,
            'status' => 200,
        ];

        $api = $this->getApiMock();
        $api->expects($this->once())
            ->method('get')
            ->with('comment/726305564')
            ->willReturn($expectedValue);

        $this->assertSame($expectedValue, $api->comment('726305564'));
    }

    public function testCreate()
    {
        $expectedValue = [
            'data' => true,
            'success' => true,
            'status' => 200,
        ];

        $api = $this->getApiMock();
        $api->expects($this->once())
            ->method('post')
            ->with('comment')
            ->willReturn($expectedValue);

        $this->assertSame($expectedValue, $api->create(['image_id' => 'ZOY11VC', 'comment' => 'I agree']));
    }

    public function testCreateParamMissing()
    {
        $this->expectException(\Imgur\Exception\MissingArgumentException::class);
        $this->expectExceptionMessage('parameters is missing');

        $this->getApiMock()->create('726305564');
    }

    public function testDeleteComment()
    {
        $expectedValue = [
            'data' => true,
            'success' => true,
            'status' => 200,
        ];

        $api = $this->getApiMock();
        $api->expects($this->once())
            ->method('delete')
            ->with('comment/726305564')
            ->willReturn($expectedValue);

        $this->assertSame($expectedValue, $api->deleteComment('726305564'));
    }

    public function testReplies()
    {
        $expectedValue = [
            'data' => [
                'id' => '726305564',
            ],
            'success' => true,
            'status' => 200,
        ];

        $api = $this->getApiMock();
        $api->expects($this->once())
            ->method('get')
            ->with('comment/726305564/replied')
            ->willReturn($expectedValue);

        $this->assertSame($expectedValue, $api->replies('726305564'));
    }

    public function testCreateReply()
    {
        $expectedValue = [
            'data' => true,
            'success' => true,
            'status' => 200,
        ];

        $api = $this->getApiMock();
        $api->expects($this->once())
            ->method('post')
            ->with('comment/726305565')
            ->willReturn($expectedValue);

        $this->assertSame($expectedValue, $api->createReply('726305565', ['image_id' => 'ZOY11VC', 'comment' => 'I agree']));
    }

    public function testCreateReplyParamMissing()
    {
        $this->expectException(\Imgur\Exception\MissingArgumentException::class);
        $this->expectExceptionMessage('parameters is missing');

        $this->getApiMock()->createReply('726305564', []);
    }

    public function testVote()
    {
        $expectedValue = [
            'data' => true,
            'success' => true,
            'status' => 200,
        ];

        $api = $this->getApiMock();
        $api->expects($this->once())
            ->method('post')
            ->with('comment/726305564/vote/up')
            ->willReturn($expectedValue);

        $this->assertSame($expectedValue, $api->vote('726305564', 'up'));
    }

    public function testVoteWrongVoteValue()
    {
        $this->expectException(\Imgur\Exception\InvalidArgumentException::class);
        $this->expectExceptionMessage('is wrong. Possible values are');

        $this->getApiMock()->vote('726305564', 'bad vote');
    }

    public function testReport()
    {
        $expectedValue = [
            'data' => true,
            'success' => true,
            'status' => 200,
        ];

        $api = $this->getApiMock();
        $api->expects($this->once())
            ->method('post')
            ->with('comment/726305564/report')
            ->willReturn($expectedValue);

        $this->assertSame($expectedValue, $api->report('726305564'));
    }

    protected function getApiClass()
    {
        return 'Imgur\Api\Comment';
    }
}


text:
'use strict';

Object.defineProperty(exports, '__esModule', {
    value: true
});

function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }

var _coreFactoryMaker = require('../../../../core/FactoryMaker');

var _coreFactoryMaker2 = _interopRequireDefault(_coreFactoryMaker);

var _utilsHandlerHelpers = require('../../utils/HandlerHelpers');

var _utilsHandlerHelpers2 = _interopRequireDefault(_utilsHandlerHelpers);

function HttpListHandler() {

    var instance = undefined,
        reportingController = undefined,
        n = undefined,
        type = undefined,
        name = undefined,
        interval = undefined;

    var storedVos = [];

    var handlerHelpers = (0, _utilsHandlerHelpers2['default'])(this.context).getInstance();

    function intervalCallback() {
        var vos = storedVos;

        if (vos.length) {
            if (reportingController) {
                reportingController.report(name, vos);
            }
        }

        storedVos = [];
    }

    function initialize(basename, rc, n_ms, requestType) {
        if (rc) {

            // this will throw if n is invalid, to be
            // caught by the initialize caller.
            n = handlerHelpers.validateN(n_ms);

            reportingController = rc;

            if (requestType && requestType.length) {
                type = requestType;
            }

            name = handlerHelpers.reconstructFullMetricName(basename, n_ms, requestType);

            interval = setInterval(intervalCallback, n);
        }
    }

    function reset() {
        clearInterval(interval);
        interval = null;
        n = null;
        type = null;
        storedVos = [];
        reportingController = null;
    }

    function handleNewMetric(metric, vo) {
        if (metric === 'HttpList') {
            if (!type || type === vo.type) {
                storedVos.push(vo);
            }
        }
    }

    instance = {
        initialize: initialize,
        reset: reset,
        handleNewMetric: handleNewMetric
    };

    return instance;
}

HttpListHandler.__dashjs_factory_name = 'HttpListHandler';
exports['default'] = _coreFactoryMaker2['default'].getClassFactory(HttpListHandler);
module.exports = exports['default'];
//# sourceMappingURL=HttpListHandler.js.map


text:
Molds give the entities form. They define the actions that entities may perform. They also define the signals entities may trigger.

## DEFINE

Molds are defined globally, meaning molds are accessible inside different worlds. Each mold must have a unique namespace across the application. To define a mold, use the following code:

```javascript

(function(){ //use a closure around the mold to give it a private scope
	var mold = uni.mold('meep');
})();

```

In the code above, there is a function closure around the mold. This is used to give the mold it's own variable scope - reducing global scope pollution and variable collisions. Inside the closure is a command that initilizes a new mold `meep` and stores it into the variable `mold`.

## ACTIONS

Once a mold is defined, actions may be added to that mold. A full mold definition with actions will look like the following:

```javascript

(function(){ //use a closure around the mold to give it a private scope
	var mold = uni.mold('meep'); //define the mold
	mold.act('log',function(pack,done){ // define action 'log'
		console.log(pack);
		done.pass();
	});
	mold.act('annoy',function(pack,done){ // define action 'annoy'
		alert(pack);
		done.pass();
	});
})();

```

For details on defining actions, look at [actions](actions.md).

## INHERITANCE

Molds may inherit actions from other molds. To do this, first define the mold to be inherited from and then use the following code:

```javascript

(function(){ //use a closure around the mold to give it a private scope
	var mold = uni.mold('meep'); //define the mold
	mold.inherit('foo'); // inherit actions from foo
})();

```

Use the code above inside the closure and after the mold has been defined. The command above will allow the mold to inherit thw actions of the mold `foo`.


text:
<?xml version="1.0" encoding="utf-8"?>
<!--
  ~ Copyright (C) 2016 Payworks GmbH (http://www.payworks.com)
  ~
  ~ The MIT License (MIT)
  ~
  ~ Permission is hereby granted, free of charge, to any person obtaining a copy
  ~ of this software and associated documentation files (the "Software"), to deal
  ~ in the Software without restriction, including without limitation the rights
  ~ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
  ~ copies of the Software, and to permit persons to whom the Software is
  ~ furnished to do so, subject to the following conditions:
  ~
  ~ The above copyright notice and this permission notice shall be included in
  ~ all copies or substantial portions of the Software.
  ~
  ~ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
  ~ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
  ~ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
  ~ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
  ~ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
  ~ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  ~ THE SOFTWARE.
  -->
<resources>
<string name="MPUAbort">"Interrompi"</string>
<string name="MPURetry">"Ripeti"</string>
<string name="MPUSendReceipt">"Invia giustificativo"</string>
<string name="MPUResendReceipt">"Invia giustificativo a nuovo"</string>
<string name="MPUClose">"Chiudi"</string>
<string name="MPUApproved">"Approvato"</string>
<string name="MPUInconclusive">"Inconcludente"</string>
<string name="MPURefunded">"Rimborsato"</string>
<string name="MPUDeclined">"Rifiutato"</string>
<string name="MPUAborted">"Interrotta"</string>
<string name="MPUPreauthorized">"Pre-autorizzato"</string>
<string name="MPUPartiallyCaptured">"della Preautorizzazione per %1$s"</string>
<string name="MPUTotal">"Totale"</string>
<string name="MPUSale">"Pagamento"</string>
<string name="MPURefund">"Rimborso"</string>
<string name="MPUUnknown">"Sconosciuto"</string>
<string name="MPUTransactionTypeSale">"Pagamento"</string>
<string name="MPUTransactionTypeRefund">"Rimborso"</string>
<string name="MPUTransactionTypePreauthorization">"Pre-autorizzazione"</string>
<string name="MPUPaymentSuccessful">"Pagamento riuscito."</string>
<string name="MPURefundApproved">"Rimborso riuscito."</string>
<string name="MPURefundDeclined">"Rimborso rifiutato."</string>
<string name="MPURefundAborted">"Rimborso interrotto."</string>
<string name="MPURefundTransaction">"Rimborsa pagamento"</string>
<string name="MPUCaptureTransaction">"Addebitare pagamento"</string>
<string name="MPUAbortTransaction">"Annulla transazione"</string>
<string name="MPURefundPrompt">"Sei sicuro di voler rimborsare questo pagamento?"</string>
<string name="MPUCapturePrompt">"Sei sicuro di voler addebitare questo pagamento?"</string>
<string name="MPUSummary">"Sommario"</string>
<string name="MPUInvalidEmailAddress">"Indirizzo email non valido"</string>
<string name="MPUEnterValidEmailAddress">"Si prega di inserire un indirizzo e-mail valido."</string>
<string name="MPUOK">"OK"</string>
<string name="MPUCouldNotSendReceipt">"Non è possibile inviare il giustificativo"</string>
<string name="MPUPleaseTryAgain">"Riprovate per favore."</string>
<string name="MPUSelectAccount">"Selezionare conto"</string>
<string name="MPUEnterEmailAddress">"Inserisci indirizzo e-mail"</string>
<string name="MPUSend">"Invia"</string>
<string name="MPUResend">"Reinvia"</string>
<string name="MPUContinue">"Avanti"</string>
<string name="MPUBackButtonDisabled">"La funzione «Indietro» è disattivata durante la procedura di pagamento. Utilizzate le funzioni in alto."</string>
<string name="MPUSignatureStatusLine">"Con la presente autorizzo il pagamento dell'importo di %1$s."</string>
<string name="MPUError">"Errore"</string>
<string name="MPUReceiptSent">"Giustificativo inviato."</string>
<string name="MPUFetching">"Caricamento del transazione"</string>
<string name="MPULoading">"Caricamento in corso..."</string>
<string name="MPUVersion">"Versione"</string>
<string name="MPULoggedInAs">"Login come"</string>
<string name="MPULogout">"Logout"</string>
<string name="MPUHelp">"Aiuto"</string>
<string name="MPUForgot">"Dati dimenticati?"</string>
<string name="MPULogin">"Login"</string>
<string name="MPUEmail">"E-mail"</string>
<string name="MPUEmailAddress">"Indirizzo e-mail"</string>
<string name="MPUPassword">"Password"</string>
<string name="MPURequired">"richiesta"</string>
<string name="MPUWrongCredentials">"La password inserita è errata o non esiste ancora un account per il vostro indirizzo e-mail."</string>
<string name="MPUUnknownUsername">"Non esiste un account con questo indirizzo email."</string>
<string name="MPUBack">"Indietro"</string>
<string name="MPUPasswordReset">"Abbiamo inviato una email con ulteriori istruzioni."</string>
<string name="MPURequestPassword">"Resetta password"</string>
<string name="MPUActions">"Azioni"</string>
<string name="MPUSettings">"Impostazioni"</string>
<string name="MPUInfo">"Info"</string>
<string name="MPUVisa">"Visa"</string>
<string name="MPUMastercard">"Mastercard"</string>
<string name="MPUMaestro">"Maestro"</string>
<string name="MPUAmericanExpress">"American Express"</string>
<string name="MPUUnionPay">"UnionPay"</string>
<string name="MPUDiners">"Diners"</string>
<string name="MPUDiscover">"Discover"</string>
<string name="MPUGhLink">"Gh-Link"</string>
<string name="MPUJcb">"JCB"</string>
<string name="MPUPrinting">"Stampando..."</string>
<string name="MPUReadCard">"Leggi Carta"</string>
<string name="MPUPrintReceipt">"Stampare giustificativo"</string>
<string name="MPUReprintReceipt">"Stampara giustificativo a nuovo"</string>
<string name="MPUCapture">"Addebitare"</string>
<string name="MPUCredit">"Credit"</string>
<string name="MPUDebit">"Debit"</string>
<string name="MPUPleaseSelect">"Please select"</string>
<string name="MPUClear">"Azzerare"</string>
</resources>


text:
echo 'Starting postgresql db server ...'

sudo systemctl start postgresql.service


text:
use utf8;
package Schema::Result::ToExtension;

# Created by DBIx::Class::Schema::Loader
# DO NOT MODIFY THE FIRST PART OF THIS FILE

=head1 NAME

Schema::Result::ToExtension

=cut

use strict;
use warnings;

use base 'DBIx::Class::Core';

=head1 TABLE: C<to_extension>

=cut

__PACKAGE__->table("to_extension");

=head1 ACCESSORS

=head2 id

  data_type: 'bigint'
  is_auto_increment: 1
  is_nullable: 0
  sequence: 'to_extension_id_seq'

=head2 name

  data_type: 'text'
  is_nullable: 0

=head2 version

  data_type: 'text'
  is_nullable: 0

=head2 info_url

  data_type: 'text'
  is_nullable: 0

=head2 script_file

  data_type: 'text'
  is_nullable: 0

=head2 isactive

  data_type: 'boolean'
  default_value: false
  is_nullable: 0

=head2 additional_config_json

  data_type: 'text'
  is_nullable: 1

=head2 description

  data_type: 'text'
  is_nullable: 1

=head2 servercheck_short_name

  data_type: 'text'
  is_nullable: 1

=head2 servercheck_column_name

  data_type: 'text'
  is_nullable: 1

=head2 type

  data_type: 'bigint'
  is_foreign_key: 1
  is_nullable: 0

=head2 last_updated

  data_type: 'timestamp with time zone'
  default_value: current_timestamp
  is_nullable: 0
  original: {default_value => \"now()"}

=cut

__PACKAGE__->add_columns(
  "id",
  {
    data_type         => "bigint",
    is_auto_increment => 1,
    is_nullable       => 0,
    sequence          => "to_extension_id_seq",
  },
  "name",
  { data_type => "text", is_nullable => 0 },
  "version",
  { data_type => "text", is_nullable => 0 },
  "info_url",
  { data_type => "text", is_nullable => 0 },
  "script_file",
  { data_type => "text", is_nullable => 0 },
  "isactive",
  { data_type => "boolean", default_value => \"false", is_nullable => 0 },
  "additional_config_json",
  { data_type => "text", is_nullable => 1 },
  "description",
  { data_type => "text", is_nullable => 1 },
  "servercheck_short_name",
  { data_type => "text", is_nullable => 1 },
  "servercheck_column_name",
  { data_type => "text", is_nullable => 1 },
  "type",
  { data_type => "bigint", is_foreign_key => 1, is_nullable => 0 },
  "last_updated",
  {
    data_type     => "timestamp with time zone",
    default_value => \"current_timestamp",
    is_nullable   => 0,
    original      => { default_value => \"now()" },
  },
);

=head1 PRIMARY KEY

=over 4

=item * L</id>

=back

=cut

__PACKAGE__->set_primary_key("id");

=head1 RELATIONS

=head2 type

Type: belongs_to

Related object: L<Schema::Result::Type>

=cut

__PACKAGE__->belongs_to(
  "type",
  "Schema::Result::Type",
  { id => "type" },
  { is_deferrable => 0, on_delete => "NO ACTION", on_update => "NO ACTION" },
);

# Created by DBIx::Class::Schema::Loader v0.07046 @ 2016-11-18 22:45:19
# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:rU86iSqXwU3lUEx55uNTIQ

# You can replace this text with custom code or comments, and it will be preserved on regeneration
#
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
#
1;