bmw-js
Version:
BMW javascript REST client for the BMW i3 hackathon.
61 lines (47 loc) • 1.64 kB
JavaScript
// Generated by CoffeeScript 1.8.0
(function() {
var MojioModel, Vehicle,
__hasProp = {}.hasOwnProperty,
__extends = function(child, parent) { for (var key in parent) { if (__hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; };
MojioModel = require('./MojioModel');
module.exports = Vehicle = (function(_super) {
__extends(Vehicle, _super);
Vehicle.prototype._schema = {
"Type": "String",
"OwnerId": "String",
"MojioId": "String",
"Name": "String",
"VIN": "String",
"LicensePlate": "String",
"IgnitionOn": "Boolean",
"LastTripEvent": "String",
"LastLocationTime": "String",
"LastLocation": "Object",
"LastSpeed": "Float",
"FuelLevel": "Float",
"LastFuelEfficiency": "Float",
"CurrentTrip": "String",
"LastTrip": "String",
"LastContactTime": "String",
"MilStatus": "Boolean",
"FaultsDetected": "Boolean",
"Viewers": "Array",
"_id": "String",
"_deleted": "Boolean"
};
Vehicle.prototype._resource = 'Vehicles';
Vehicle.prototype._model = 'Vehicle';
function Vehicle(json) {
Vehicle.__super__.constructor.call(this, json);
}
Vehicle._resource = 'Vehicles';
Vehicle._model = 'Vehicle';
Vehicle.resource = function() {
return Vehicle._resource;
};
Vehicle.model = function() {
return Vehicle._model;
};
return Vehicle;
})(MojioModel);
}).call(this);