This project has retired. For details please refer to its Attic page.
Operator xref
View Javadoc
1   /*
2    * Copyright 2001-2008 The Apache Software Foundation.
3    * 
4    * Licensed under the Apache License, Version 2.0 (the "License");
5    * you may not use this file except in compliance with the License.
6    * You may obtain a copy of the License at
7    * 
8    *      http://www.apache.org/licenses/LICENSE-2.0
9    * 
10   * Unless required by applicable law or agreed to in writing, software
11   * distributed under the License is distributed on an "AS IS" BASIS,
12   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13   * See the License for the specific language governing permissions and
14   * limitations under the License.
15   *
16   */
17  package org.apache.juddi.model;
18  
19  import java.io.Serializable;
20  import java.util.ArrayList;
21  import java.util.List;
22  import javax.persistence.CascadeType;
23  import javax.persistence.Column;
24  import javax.persistence.Entity;
25  import javax.persistence.FetchType;
26  import javax.persistence.GeneratedValue;
27  import javax.persistence.GenerationType;
28  import javax.persistence.Id;
29  import javax.persistence.JoinColumn;
30  import javax.persistence.ManyToOne;
31  import javax.persistence.OneToMany;
32  import javax.persistence.Table;
33  
34  
35  @Entity
36  @Table(name = "j3_operator")
37  public class Operator implements Serializable {
38  
39          private String operatorNodeID;
40          private OperatorStatusType operatorStatus;
41          private List<Contact> contact;
42          private String soapReplicationURL;
43          private List<KeyInfo> keyInfo;
44          Long id;
45          ReplicationConfiguration parent;
46          
47                    @Id
48          @GeneratedValue(strategy = GenerationType.AUTO)
49          public Long getId() {
50                  return id;
51          }
52  
53          public void setId(Long id) {
54                  this.id = id;
55          }
56          @Column(name="operator_node")
57          public String getOperatorNodeID() {
58                  return operatorNodeID;
59          }
60          public void setOperatorNodeID(String value) {
61                  this.operatorNodeID = value;
62          }
63  
64          @Column(name = "operator_status")
65          public OperatorStatusType getOperatorStatus() {
66                  return operatorStatus;
67          }
68  
69          public void setOperatorStatus(OperatorStatusType value) {
70                  this.operatorStatus = value;
71          }
72  
73          @OneToMany(cascade = CascadeType.ALL, fetch = FetchType.LAZY, targetEntity = Contact.class)
74          public List<Contact> getContact() {
75                  if (contact == null) {
76                          contact = new ArrayList<Contact>();
77                  }
78                  return this.contact;
79          }
80  
81          public void setContact(List<Contact> c) {
82  
83                  this.contact = c;
84          }
85  
86          @Column(name = "replicationurl")
87          public String getSoapReplicationURL() {
88                  return soapReplicationURL;
89          }
90  
91          public void setSoapReplicationURL(String value) {
92                  this.soapReplicationURL = value;
93          }
94  
95          @OneToMany(cascade = CascadeType.ALL, fetch = FetchType.LAZY, targetEntity = KeyInfo.class)
96          public List<KeyInfo> getKeyInfo() {
97                  if (keyInfo == null) {
98                          keyInfo = new ArrayList<KeyInfo>();
99                  }
100                 return this.keyInfo;
101         }
102         
103         public void setKeyInfo(List<KeyInfo> c) {
104                 this.keyInfo=c;
105         }
106         
107          @ManyToOne(fetch = FetchType.LAZY)
108         @JoinColumn(name = "entity_key_ed", nullable = true)
109         public ReplicationConfiguration getParent() {
110                 return this.parent;
111         }
112         
113 
114         public void setParent(ReplicationConfiguration e) {
115                 this.parent = e;
116         }
117 }