1
22
23 package com.liferay.portlet.expando.model;
24
25 import java.io.Serializable;
26
27 import java.util.ArrayList;
28 import java.util.List;
29
30
48 public class ExpandoRowSoap implements Serializable {
49 public static ExpandoRowSoap toSoapModel(ExpandoRow model) {
50 ExpandoRowSoap soapModel = new ExpandoRowSoap();
51
52 soapModel.setRowId(model.getRowId());
53 soapModel.setCompanyId(model.getCompanyId());
54 soapModel.setTableId(model.getTableId());
55 soapModel.setClassPK(model.getClassPK());
56
57 return soapModel;
58 }
59
60 public static ExpandoRowSoap[] toSoapModels(ExpandoRow[] models) {
61 ExpandoRowSoap[] soapModels = new ExpandoRowSoap[models.length];
62
63 for (int i = 0; i < models.length; i++) {
64 soapModels[i] = toSoapModel(models[i]);
65 }
66
67 return soapModels;
68 }
69
70 public static ExpandoRowSoap[][] toSoapModels(ExpandoRow[][] models) {
71 ExpandoRowSoap[][] soapModels = null;
72
73 if (models.length > 0) {
74 soapModels = new ExpandoRowSoap[models.length][models[0].length];
75 }
76 else {
77 soapModels = new ExpandoRowSoap[0][0];
78 }
79
80 for (int i = 0; i < models.length; i++) {
81 soapModels[i] = toSoapModels(models[i]);
82 }
83
84 return soapModels;
85 }
86
87 public static ExpandoRowSoap[] toSoapModels(List<ExpandoRow> models) {
88 List<ExpandoRowSoap> soapModels = new ArrayList<ExpandoRowSoap>(models.size());
89
90 for (ExpandoRow model : models) {
91 soapModels.add(toSoapModel(model));
92 }
93
94 return soapModels.toArray(new ExpandoRowSoap[soapModels.size()]);
95 }
96
97 public ExpandoRowSoap() {
98 }
99
100 public long getPrimaryKey() {
101 return _rowId;
102 }
103
104 public void setPrimaryKey(long pk) {
105 setRowId(pk);
106 }
107
108 public long getRowId() {
109 return _rowId;
110 }
111
112 public void setRowId(long rowId) {
113 _rowId = rowId;
114 }
115
116 public long getCompanyId() {
117 return _companyId;
118 }
119
120 public void setCompanyId(long companyId) {
121 _companyId = companyId;
122 }
123
124 public long getTableId() {
125 return _tableId;
126 }
127
128 public void setTableId(long tableId) {
129 _tableId = tableId;
130 }
131
132 public long getClassPK() {
133 return _classPK;
134 }
135
136 public void setClassPK(long classPK) {
137 _classPK = classPK;
138 }
139
140 private long _rowId;
141 private long _companyId;
142 private long _tableId;
143 private long _classPK;
144 }