PageRenderTime 16ms CodeModel.GetById 13ms app.highlight 1ms RepoModel.GetById 1ms app.codeStats 0ms

/tests/com/google/appengine/datanucleus/test/DetachableWithMultiValuePropsJDO.java

http://datanucleus-appengine.googlecode.com/
Java | 52 lines | 24 code | 9 blank | 19 comment | 0 complexity | 21706fcbdd5a009e34db46eb2d1966d5 MD5 | raw file
 1/*
 2 * /**********************************************************************
 3 * Copyright (c) 2009 Google Inc.
 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
18package com.google.appengine.datanucleus.test;
19
20import java.io.Serializable;
21import java.util.List;
22
23import javax.jdo.annotations.IdGeneratorStrategy;
24import javax.jdo.annotations.PersistenceCapable;
25import javax.jdo.annotations.Persistent;
26import javax.jdo.annotations.PrimaryKey;
27
28/**
29 * @author Max Ross <maxr@google.com>
30 */
31@PersistenceCapable(detachable = "true")
32public class DetachableWithMultiValuePropsJDO implements Serializable {
33
34  @PrimaryKey
35  @Persistent(valueStrategy = IdGeneratorStrategy.IDENTITY)
36  Long id;
37
38  @Persistent
39  List<String> strList;
40
41  public Long getId() {
42    return id;
43  }
44
45  public List<String> getStrList() {
46    return strList;
47  }
48
49  public void setStrList(List<String> strList) {
50    this.strList = strList;
51  }
52}