/src/main/java/com/google/ie/business/domain/BadWord.java

http://thoughtsite.googlecode.com/ · Java · 76 lines · 36 code · 13 blank · 27 comment · 0 complexity · 1636b46cf4f7c59c6ba834b3e6fcbbc1 MD5 · raw file

  1. /* Copyright 2010 Google Inc.
  2. *
  3. * Licensed under the Apache License, Version 2.0 (the "License");
  4. * you may not use this file except in compliance with the License.
  5. * You may obtain a copy of the License at
  6. *
  7. * http://www.apache.org/licenses/LICENSE-2.0
  8. *
  9. * Unless required by applicable law or agreed to in writing, software
  10. * distributed under the License is distributed on an "AS IS" BASIS.
  11. * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  12. * See the License for the specific language governing permissions and
  13. * limitations under the License
  14. */
  15. package com.google.ie.business.domain;
  16. import org.compass.annotations.Searchable;
  17. import org.compass.annotations.SearchableId;
  18. import org.compass.annotations.SearchableProperty;
  19. import java.io.Serializable;
  20. import javax.jdo.annotations.Extension;
  21. import javax.jdo.annotations.IdGeneratorStrategy;
  22. import javax.jdo.annotations.IdentityType;
  23. import javax.jdo.annotations.PersistenceCapable;
  24. import javax.jdo.annotations.Persistent;
  25. import javax.jdo.annotations.PrimaryKey;
  26. @PersistenceCapable(identityType = IdentityType.APPLICATION, detachable = "true")
  27. @Searchable(alias = "BadWord")
  28. public class BadWord implements Serializable {
  29. /** A unique identifier for the class */
  30. private static final long serialVersionUID = 8171320030754551639L;
  31. @PrimaryKey
  32. @Persistent(valueStrategy = IdGeneratorStrategy.IDENTITY)
  33. @Extension(vendorName = "datanucleus", key = "gae.encoded-pk", value = "true")
  34. @SearchableId
  35. private String key;
  36. @Persistent
  37. @SearchableProperty
  38. private String word;
  39. /**
  40. * @return the key
  41. */
  42. public String getKey() {
  43. return key;
  44. }
  45. /**
  46. * @param key the key to set
  47. */
  48. public void setKey(String key) {
  49. this.key = key;
  50. }
  51. /**
  52. * @return the word
  53. */
  54. public String getWord() {
  55. return word;
  56. }
  57. /**
  58. * @param word the word to set
  59. */
  60. public void setWord(String word) {
  61. this.word = word;
  62. }
  63. }