1 package be
.nikiroo
.jvcard
;
3 import java
.security
.InvalidParameterException
;
4 import java
.util
.LinkedList
;
11 private int b64
; // -1 = no, 0 = still not ordered, the rest is order
12 private List
<TypeInfo
> types
;
13 private boolean dirty
;
14 private Contact parent
;
16 public Data(List
<TypeInfo
> types
, String name
, String value
, String group
) {
18 types
= new LinkedList
<TypeInfo
>();
27 for (TypeInfo type
: types
) {
28 if (type
.getName().equals("ENCODING")
29 && type
.getValue().equals("b")) {
36 public List
<TypeInfo
> getTypes() {
40 public String
getName() {
44 public String
getValue() {
48 public String
getGroup() {
52 public int getB64Key() {
56 void resetB64Key(int i
) {
58 throw new InvalidParameterException(
59 "Cannot add a BKey on a non-binary object");
61 throw new InvalidParameterException(
62 "Cannot remove the BKey on a binary object");
67 public boolean isBinary() {
71 public boolean isDirty() {
75 public void setParent(Contact parent
) {