UNPKG

sprotty

Version:

A next-gen framework for graphical views

59 lines 3.96 kB
"use strict"; /******************************************************************************** * Copyright (c) 2019 TypeFox and others. * * This program and the accompanying materials are made available under the * terms of the Eclipse Public License v. 2.0 which is available at * http://www.eclipse.org/legal/epl-2.0. * * This Source Code may also be made available under the following Secondary * Licenses when the conditions for such availability set forth in the Eclipse * Public License v. 2.0 are satisfied: GNU General Public License, version 2 * with the GNU Classpath Exception which is available at * https://www.gnu.org/software/classpath/license.html. * * SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0 ********************************************************************************/ Object.defineProperty(exports, "__esModule", { value: true }); const inversify_1 = require("inversify"); const types_1 = require("../../base/types"); const manhattan_edge_router_1 = require("./manhattan-edge-router"); const polyline_edge_router_1 = require("./polyline-edge-router"); const manhattan_anchors_1 = require("./manhattan-anchors"); const polyline_anchors_1 = require("./polyline-anchors"); const anchor_1 = require("./anchor"); const routing_1 = require("./routing"); const bezier_edge_router_1 = require("./bezier-edge-router"); const bezier_anchors_1 = require("./bezier-anchors"); const command_registration_1 = require("../../base/commands/command-registration"); const routingModule = new inversify_1.ContainerModule((bind, _unbind, isBound) => { bind(routing_1.EdgeRouterRegistry).toSelf().inSingletonScope(); bind(anchor_1.AnchorComputerRegistry).toSelf().inSingletonScope(); bind(manhattan_edge_router_1.ManhattanEdgeRouter).toSelf().inSingletonScope(); bind(types_1.TYPES.IEdgeRouter).toService(manhattan_edge_router_1.ManhattanEdgeRouter); bind(manhattan_anchors_1.ManhattanEllipticAnchor).toSelf().inSingletonScope(); bind(types_1.TYPES.IAnchorComputer).toService(manhattan_anchors_1.ManhattanEllipticAnchor); bind(manhattan_anchors_1.ManhattanRectangularAnchor).toSelf().inSingletonScope(); bind(types_1.TYPES.IAnchorComputer).toService(manhattan_anchors_1.ManhattanRectangularAnchor); bind(manhattan_anchors_1.ManhattanDiamondAnchor).toSelf().inSingletonScope(); bind(types_1.TYPES.IAnchorComputer).toService(manhattan_anchors_1.ManhattanDiamondAnchor); bind(polyline_edge_router_1.PolylineEdgeRouter).toSelf().inSingletonScope(); bind(types_1.TYPES.IEdgeRouter).toService(polyline_edge_router_1.PolylineEdgeRouter); bind(polyline_anchors_1.EllipseAnchor).toSelf().inSingletonScope(); bind(types_1.TYPES.IAnchorComputer).toService(polyline_anchors_1.EllipseAnchor); bind(polyline_anchors_1.RectangleAnchor).toSelf().inSingletonScope(); bind(types_1.TYPES.IAnchorComputer).toService(polyline_anchors_1.RectangleAnchor); bind(polyline_anchors_1.DiamondAnchor).toSelf().inSingletonScope(); bind(types_1.TYPES.IAnchorComputer).toService(polyline_anchors_1.DiamondAnchor); bind(bezier_edge_router_1.BezierEdgeRouter).toSelf().inSingletonScope(); bind(types_1.TYPES.IEdgeRouter).toService(bezier_edge_router_1.BezierEdgeRouter); bind(bezier_anchors_1.BezierEllipseAnchor).toSelf().inSingletonScope(); bind(types_1.TYPES.IAnchorComputer).toService(bezier_anchors_1.BezierEllipseAnchor); bind(bezier_anchors_1.BezierRectangleAnchor).toSelf().inSingletonScope(); bind(types_1.TYPES.IAnchorComputer).toService(bezier_anchors_1.BezierRectangleAnchor); bind(bezier_anchors_1.BezierDiamondAnchor).toSelf().inSingletonScope(); bind(types_1.TYPES.IAnchorComputer).toService(bezier_anchors_1.BezierDiamondAnchor); (0, command_registration_1.configureCommand)({ bind, isBound }, bezier_edge_router_1.AddRemoveBezierSegmentCommand); }); exports.default = routingModule; //# sourceMappingURL=di.config.js.map