Matteo Scandolo | fb46ae6 | 2017-08-08 09:10:50 -0700 | [diff] [blame] | 1 | |
| 2 | /* |
| 3 | * Copyright 2017-present Open Networking Foundation |
| 4 | |
| 5 | * Licensed under the Apache License, Version 2.0 (the "License"); |
| 6 | * you may not use this file except in compliance with the License. |
| 7 | * You may obtain a copy of the License at |
| 8 | |
| 9 | * http://www.apache.org/licenses/LICENSE-2.0 |
| 10 | |
| 11 | * Unless required by applicable law or agreed to in writing, software |
| 12 | * distributed under the License is distributed on an "AS IS" BASIS, |
| 13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 14 | * See the License for the specific language governing permissions and |
| 15 | * limitations under the License. |
| 16 | */ |
| 17 | |
| 18 | |
Matteo Scandolo | a62adbc | 2017-03-02 15:37:34 -0800 | [diff] [blame] | 19 | import {xosDataSources} from '../datasources/index'; |
Matteo Scandolo | 7218159 | 2017-07-25 14:49:40 -0700 | [diff] [blame] | 20 | import {XosServiceGraphStore} from './services/service-graph.store'; |
Matteo Scandolo | a62adbc | 2017-03-02 15:37:34 -0800 | [diff] [blame] | 21 | import {xosCore} from '../core/index'; |
Matteo Scandolo | 968e7f2 | 2017-03-03 11:49:18 -0800 | [diff] [blame] | 22 | import {XosCoarseTenancyGraph} from './components/coarse/coarse.component'; |
Matteo Scandolo | 7517178 | 2017-03-08 14:17:01 -0800 | [diff] [blame] | 23 | import {XosFineGrainedTenancyGraph} from './components/fine-grained/fine-grained.component'; |
Matteo Scandolo | 7629cc4 | 2017-03-13 14:12:15 -0700 | [diff] [blame] | 24 | import {XosServiceGraphExtender, IXosServiceGraphExtender} from './services/graph.extender'; |
| 25 | import {XosGraphHelpers} from './services/d3-helpers/graph.helpers'; |
Matteo Scandolo | 7218159 | 2017-07-25 14:49:40 -0700 | [diff] [blame] | 26 | import {XosServiceInstanceGraphStore} from './services/service-instance.graph.store'; |
Matteo Scandolo | a62adbc | 2017-03-02 15:37:34 -0800 | [diff] [blame] | 27 | export const xosServiceGraph = 'xosServiceGraph'; |
| 28 | |
| 29 | angular |
| 30 | .module(xosServiceGraph, [xosDataSources, xosCore]) |
| 31 | .service('XosServiceGraphStore', XosServiceGraphStore) |
Matteo Scandolo | 7218159 | 2017-07-25 14:49:40 -0700 | [diff] [blame] | 32 | .service('XosServiceInstanceGraphStore', XosServiceInstanceGraphStore) |
Matteo Scandolo | 7629cc4 | 2017-03-13 14:12:15 -0700 | [diff] [blame] | 33 | .service('XosServiceGraphExtender', XosServiceGraphExtender) |
| 34 | .service('XosGraphHelpers', XosGraphHelpers) |
Matteo Scandolo | 968e7f2 | 2017-03-03 11:49:18 -0800 | [diff] [blame] | 35 | .component('xosCoarseTenancyGraph', XosCoarseTenancyGraph) |
Matteo Scandolo | 7517178 | 2017-03-08 14:17:01 -0800 | [diff] [blame] | 36 | .component('xosFineGrainedTenancyGraph', XosFineGrainedTenancyGraph) |
| 37 | .config(($stateProvider) => { |
| 38 | $stateProvider |
| 39 | .state('xos.fine-grained-graph', { |
| 40 | url: 'tenancy-graph', |
| 41 | component: 'xosFineGrainedTenancyGraph', |
| 42 | }); |
| 43 | }) |
Matteo Scandolo | 7629cc4 | 2017-03-13 14:12:15 -0700 | [diff] [blame] | 44 | .run(($log: ng.ILogService, XosServiceGraphExtender: IXosServiceGraphExtender) => { |
Matteo Scandolo | a62adbc | 2017-03-02 15:37:34 -0800 | [diff] [blame] | 45 | $log.info(`[${xosServiceGraph}] Module Setup`); |
| 46 | }); |