1   /**
2    * Copyright (c) 2000-2010 Liferay, Inc. All rights reserved.
3    *
4    * The contents of this file are subject to the terms of the Liferay Enterprise
5    * Subscription License ("License"). You may not use this file except in
6    * compliance with the License. You can obtain a copy of the License by
7    * contacting Liferay, Inc. See the License for the specific language governing
8    * permissions and limitations under the License, including but not limited to
9    * distribution rights of the Software.
10   *
11   *
12   *
13   */
14  
15  package com.liferay.portlet.tags.model;
16  
17  import java.io.Serializable;
18  
19  import java.util.ArrayList;
20  import java.util.List;
21  
22  /**
23   * <a href="TagsSourceSoap.java.html"><b><i>View Source</i></b></a>
24   *
25   * <p>
26   * ServiceBuilder generated this class. Modifications in this class will be
27   * overwritten the next time is generated.
28   * </p>
29   *
30   * <p>
31   * This class is used by
32   * {@link com.liferay.portlet.tags.service.http.TagsSourceServiceSoap}.
33   * </p>
34   *
35   * @author    Brian Wing Shun Chan
36   * @see       com.liferay.portlet.tags.service.http.TagsSourceServiceSoap
37   * @generated
38   */
39  public class TagsSourceSoap implements Serializable {
40      public static TagsSourceSoap toSoapModel(TagsSource model) {
41          TagsSourceSoap soapModel = new TagsSourceSoap();
42  
43          soapModel.setSourceId(model.getSourceId());
44          soapModel.setParentSourceId(model.getParentSourceId());
45          soapModel.setName(model.getName());
46          soapModel.setAcronym(model.getAcronym());
47  
48          return soapModel;
49      }
50  
51      public static TagsSourceSoap[] toSoapModels(TagsSource[] models) {
52          TagsSourceSoap[] soapModels = new TagsSourceSoap[models.length];
53  
54          for (int i = 0; i < models.length; i++) {
55              soapModels[i] = toSoapModel(models[i]);
56          }
57  
58          return soapModels;
59      }
60  
61      public static TagsSourceSoap[][] toSoapModels(TagsSource[][] models) {
62          TagsSourceSoap[][] soapModels = null;
63  
64          if (models.length > 0) {
65              soapModels = new TagsSourceSoap[models.length][models[0].length];
66          }
67          else {
68              soapModels = new TagsSourceSoap[0][0];
69          }
70  
71          for (int i = 0; i < models.length; i++) {
72              soapModels[i] = toSoapModels(models[i]);
73          }
74  
75          return soapModels;
76      }
77  
78      public static TagsSourceSoap[] toSoapModels(List<TagsSource> models) {
79          List<TagsSourceSoap> soapModels = new ArrayList<TagsSourceSoap>(models.size());
80  
81          for (TagsSource model : models) {
82              soapModels.add(toSoapModel(model));
83          }
84  
85          return soapModels.toArray(new TagsSourceSoap[soapModels.size()]);
86      }
87  
88      public TagsSourceSoap() {
89      }
90  
91      public long getPrimaryKey() {
92          return _sourceId;
93      }
94  
95      public void setPrimaryKey(long pk) {
96          setSourceId(pk);
97      }
98  
99      public long getSourceId() {
100         return _sourceId;
101     }
102 
103     public void setSourceId(long sourceId) {
104         _sourceId = sourceId;
105     }
106 
107     public long getParentSourceId() {
108         return _parentSourceId;
109     }
110 
111     public void setParentSourceId(long parentSourceId) {
112         _parentSourceId = parentSourceId;
113     }
114 
115     public String getName() {
116         return _name;
117     }
118 
119     public void setName(String name) {
120         _name = name;
121     }
122 
123     public String getAcronym() {
124         return _acronym;
125     }
126 
127     public void setAcronym(String acronym) {
128         _acronym = acronym;
129     }
130 
131     private long _sourceId;
132     private long _parentSourceId;
133     private String _name;
134     private String _acronym;
135 }