1: using System.Collections;
2: using System.Collections.Generic;
3: using System.Data;
4: using System.Linq;
5:
6: namespace Ia.Ngn.Cl.Model.Data.Huawei
7: {
8: ////////////////////////////////////////////////////////////////////////////
9:
10: /// <summary publish="true">
11: /// Huawei's Sbr Entity Framework class for Optical Fiber Network (OFN) data model.
12: /// </summary>
13: ///
14: /// <remarks>
15: /// Copyright © 2014-2017 Jasem Y. Al-Shamlan (info@ia.com.kw), Integrated Applications - Kuwait. All Rights Reserved.
16: ///
17: /// This library is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by
18: /// the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
19: ///
20: /// This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of
21: /// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
22: ///
23: /// You should have received a copy of the GNU General Public License along with this library. If not, see http://www.gnu.org/licenses.
24: ///
25: /// Copyright notice: This notice may not be removed or altered from any source distribution.
26: /// </remarks>
27: public class HuSbr
28: {
29: /// <summary/>
30: public HuSbr() { }
31:
32: ////////////////////////////////////////////////////////////////////////////
33:
34: /// <summary>
35: ///
36: /// </summary>
37: public static Ia.Ngn.Cl.Model.Huawei.HuSbr Read(string impu)
38: {
39: Ia.Ngn.Cl.Model.Huawei.HuSbr huSbr;
40:
41: using (var db = new Ia.Ngn.Cl.Model.Ngn())
42: {
43: huSbr = (from s in db.HuSbrs where s.IMPU == impu select s).SingleOrDefault();
44: }
45:
46: return huSbr;
47: }
48:
49: /*
50: ////////////////////////////////////////////////////////////////////////////
51:
52: /// <summary>
53: ///
54: /// </summary>
55: public static List<Ia.Ngn.Cl.Model.Huawei.HuSbr> ReadList(ArrayList impuList)
56: {
57: long i;
58: long[] sp;
59: List<Ia.Ngn.Cl.Model.Huawei.HuSbr> huSbrList;
60:
61: i = 0;
62: sp = new long[impuList.Count];
63:
64: foreach (long l in impuList) sp[i++] = l;
65:
66: using (var db = new Ia.Ngn.Cl.Model.Ngn())
67: {
68: //serviceList = (from q in db.Services where dnList.Contains(q.DN) select q).ToList();
69:
70: // var pages = context.Pages.Where(x => keys.Any(key => x.Title.Contains(key)));
71: huSbrList = db.HuSbrs.Where(q => sp.Any(v => q.IMPU == v.ToString())).ToList();
72: }
73:
74: return huSbrList;
75: }
76: */
77:
78: ////////////////////////////////////////////////////////////////////////////
79:
80: /// <summary>
81: ///
82: /// </summary>
83: public static List<string> ServicePbxList()
84: {
85: var list = new List<string>();
86:
87: return list;
88: }
89:
90: ////////////////////////////////////////////////////////////////////////////
91: ////////////////////////////////////////////////////////////////////////////
92: }
93:
94: ////////////////////////////////////////////////////////////////////////////
95: ////////////////////////////////////////////////////////////////////////////
96: }