|
Lines 34-39
Link Here
|
| 34 |
public boolean isSystem = false; |
34 |
public boolean isSystem = false; |
| 35 |
public URI location; |
35 |
public URI location; |
| 36 |
public String name; |
36 |
public String name; |
|
|
37 |
public String nickname; |
| 37 |
public SoftReference repository; |
38 |
public SoftReference repository; |
| 38 |
public String suffix; |
39 |
public String suffix; |
| 39 |
|
40 |
|
|
Lines 48-53
Link Here
|
| 48 |
public static final String KEY_DESCRIPTION = "description"; //$NON-NLS-1$ |
49 |
public static final String KEY_DESCRIPTION = "description"; //$NON-NLS-1$ |
| 49 |
public static final String KEY_ENABLED = "enabled"; //$NON-NLS-1$ |
50 |
public static final String KEY_ENABLED = "enabled"; //$NON-NLS-1$ |
| 50 |
public static final String KEY_NAME = "name"; //$NON-NLS-1$ |
51 |
public static final String KEY_NAME = "name"; //$NON-NLS-1$ |
|
|
52 |
public static final String KEY_NICKNAME = "nickname"; //$NON-NLS-1$ |
| 51 |
public static final String KEY_PROVIDER = "provider"; //$NON-NLS-1$ |
53 |
public static final String KEY_PROVIDER = "provider"; //$NON-NLS-1$ |
| 52 |
public static final String KEY_SUFFIX = "suffix"; //$NON-NLS-1$ |
54 |
public static final String KEY_SUFFIX = "suffix"; //$NON-NLS-1$ |
| 53 |
public static final String KEY_SYSTEM = "isSystem"; //$NON-NLS-1$ |
55 |
public static final String KEY_SYSTEM = "isSystem"; //$NON-NLS-1$ |
|
Lines 491-500
Link Here
|
| 491 |
return null;// Repository not found |
493 |
return null;// Repository not found |
| 492 |
if (IRepository.PROP_DESCRIPTION.equals(key)) |
494 |
if (IRepository.PROP_DESCRIPTION.equals(key)) |
| 493 |
return info.description; |
495 |
return info.description; |
| 494 |
if (IRepository.PROP_NAME.equals(key)) |
496 |
else if (IRepository.PROP_NAME.equals(key)) |
| 495 |
return info.name; |
497 |
return info.name; |
| 496 |
if (IRepository.PROP_SYSTEM.equals(key)) |
498 |
else if (IRepository.PROP_SYSTEM.equals(key)) |
| 497 |
return Boolean.toString(info.isSystem); |
499 |
return Boolean.toString(info.isSystem); |
|
|
500 |
else if (IRepository.PROP_NICKNAME.equals(key)) |
| 501 |
return info.nickname; |
| 498 |
// Key not known, return null |
502 |
// Key not known, return null |
| 499 |
return null; |
503 |
return null; |
| 500 |
} |
504 |
} |
|
Lines 512-521
Link Here
|
| 512 |
return;// Repository not found |
516 |
return;// Repository not found |
| 513 |
if (IRepository.PROP_DESCRIPTION.equals(key)) |
517 |
if (IRepository.PROP_DESCRIPTION.equals(key)) |
| 514 |
info.description = value; |
518 |
info.description = value; |
| 515 |
if (IRepository.PROP_NAME.equals(key)) |
519 |
else if (IRepository.PROP_NAME.equals(key)) |
| 516 |
info.name = value; |
520 |
info.name = value; |
| 517 |
if (IRepository.PROP_SYSTEM.equals(key)) |
521 |
else if (IRepository.PROP_NICKNAME.equals(key)) |
| 518 |
//only true is value.equals("true") which is OK because a repository is only system if it's explicitly set to system. |
522 |
info.nickname = value; |
|
|
523 |
else if (IRepository.PROP_SYSTEM.equals(key)) |
| 524 |
//only true if value.equals("true") which is OK because a repository is only system if it's explicitly set to system. |
| 519 |
info.isSystem = Boolean.valueOf(value).booleanValue(); |
525 |
info.isSystem = Boolean.valueOf(value).booleanValue(); |
| 520 |
// Key not known |
526 |
// Key not known |
| 521 |
} |
527 |
} |
|
Lines 712-717
Link Here
|
| 712 |
changed |= putValue(node, KEY_SYSTEM, Boolean.toString(info.isSystem)); |
718 |
changed |= putValue(node, KEY_SYSTEM, Boolean.toString(info.isSystem)); |
| 713 |
changed |= putValue(node, KEY_DESCRIPTION, info.description); |
719 |
changed |= putValue(node, KEY_DESCRIPTION, info.description); |
| 714 |
changed |= putValue(node, KEY_NAME, info.name); |
720 |
changed |= putValue(node, KEY_NAME, info.name); |
|
|
721 |
changed |= putValue(node, KEY_NICKNAME, info.nickname); |
| 715 |
changed |= putValue(node, KEY_SUFFIX, info.suffix); |
722 |
changed |= putValue(node, KEY_SUFFIX, info.suffix); |
| 716 |
changed |= putValue(node, KEY_ENABLED, Boolean.toString(info.isEnabled)); |
723 |
changed |= putValue(node, KEY_ENABLED, Boolean.toString(info.isEnabled)); |
| 717 |
if (changed && flush) |
724 |
if (changed && flush) |
|
Lines 788-793
Link Here
|
| 788 |
RepositoryInfo info = new RepositoryInfo(); |
795 |
RepositoryInfo info = new RepositoryInfo(); |
| 789 |
info.location = location; |
796 |
info.location = location; |
| 790 |
info.name = child.get(KEY_NAME, null); |
797 |
info.name = child.get(KEY_NAME, null); |
|
|
798 |
info.nickname = child.get(KEY_NICKNAME, null); |
| 791 |
info.description = child.get(KEY_DESCRIPTION, null); |
799 |
info.description = child.get(KEY_DESCRIPTION, null); |
| 792 |
info.isSystem = child.getBoolean(KEY_SYSTEM, false); |
800 |
info.isSystem = child.getBoolean(KEY_SYSTEM, false); |
| 793 |
info.isEnabled = child.getBoolean(KEY_ENABLED, true); |
801 |
info.isEnabled = child.getBoolean(KEY_ENABLED, true); |