1 18 19 20 package sync4j.framework.core; 21 22 30 public final class SourceRef 31 implements java.io.Serializable { 32 33 private String value; 35 private Source source; 36 37 39 43 public SourceRef() {} 44 45 53 public SourceRef(final String value) { 54 setValue(value); 55 } 56 57 65 public SourceRef(final Source source) { 66 setSource(source); 67 68 value = source.getLocURI(); 69 } 70 71 73 78 public String getValue() { 79 return value; 80 } 81 82 87 public void setValue(String value) { 88 this.value = (value == null) ? "" : value; 89 } 90 91 96 public Source getSource() { 97 return this.source; 98 } 99 100 105 public void setSource(Source source) { 106 if (source == null) { 107 throw new IllegalArgumentException ("source cannot be null"); 108 } 109 this.source = source; 110 } 111 } | Popular Tags |