001/*
002 * The contents of this file are subject to the terms of the Common Development and
003 * Distribution License (the License). You may not use this file except in compliance with the
004 * License.
005 *
006 * You can obtain a copy of the License at legal/CDDLv1.0.txt. See the License for the
007 * specific language governing permission and limitations under the License.
008 *
009 * When distributing Covered Software, include this CDDL Header Notice in each file and include
010 * the License file at legal/CDDLv1.0.txt. If applicable, add the following below the CDDL
011 * Header, with the fields enclosed by brackets [] replaced by your own identifying
012 * information: "Portions Copyright [year] [name of copyright owner]".
013 *
014 * Copyright 2008 Sun Microsystems, Inc.
015 */
016package org.opends.server.admin.std.meta;
017
018
019
020import java.util.Collection;
021import java.util.SortedSet;
022import org.forgerock.opendj.ldap.DN;
023import org.opends.server.admin.AdministratorAction;
024import org.opends.server.admin.AliasDefaultBehaviorProvider;
025import org.opends.server.admin.BooleanPropertyDefinition;
026import org.opends.server.admin.ClassPropertyDefinition;
027import org.opends.server.admin.client.AuthorizationException;
028import org.opends.server.admin.client.CommunicationException;
029import org.opends.server.admin.client.ConcurrentModificationException;
030import org.opends.server.admin.client.ManagedObject;
031import org.opends.server.admin.client.MissingMandatoryPropertiesException;
032import org.opends.server.admin.client.OperationRejectedException;
033import org.opends.server.admin.DefaultBehaviorProvider;
034import org.opends.server.admin.DefinedDefaultBehaviorProvider;
035import org.opends.server.admin.DNPropertyDefinition;
036import org.opends.server.admin.EnumPropertyDefinition;
037import org.opends.server.admin.ManagedObjectAlreadyExistsException;
038import org.opends.server.admin.ManagedObjectDefinition;
039import org.opends.server.admin.ManagedObjectOption;
040import org.opends.server.admin.PropertyException;
041import org.opends.server.admin.PropertyOption;
042import org.opends.server.admin.PropertyProvider;
043import org.opends.server.admin.server.ConfigurationChangeListener;
044import org.opends.server.admin.server.ServerManagedObject;
045import org.opends.server.admin.std.client.TrustStoreBackendCfgClient;
046import org.opends.server.admin.std.meta.BackendCfgDefn.WritabilityMode;
047import org.opends.server.admin.std.server.BackendCfg;
048import org.opends.server.admin.std.server.TrustStoreBackendCfg;
049import org.opends.server.admin.StringPropertyDefinition;
050import org.opends.server.admin.Tag;
051import org.opends.server.admin.UndefinedDefaultBehaviorProvider;
052
053
054
055/**
056 * An interface for querying the Trust Store Backend managed object
057 * definition meta information.
058 * <p>
059 * The Trust Store Backend provides an LDAP view of a file-based trust
060 * store. It is used by the administrative cryptographic framework.
061 */
062public final class TrustStoreBackendCfgDefn extends ManagedObjectDefinition<TrustStoreBackendCfgClient, TrustStoreBackendCfg> {
063
064  // The singleton configuration definition instance.
065  private static final TrustStoreBackendCfgDefn INSTANCE = new TrustStoreBackendCfgDefn();
066
067
068
069  // The "java-class" property definition.
070  private static final ClassPropertyDefinition PD_JAVA_CLASS;
071
072
073
074  // The "trust-store-file" property definition.
075  private static final StringPropertyDefinition PD_TRUST_STORE_FILE;
076
077
078
079  // The "trust-store-pin" property definition.
080  private static final StringPropertyDefinition PD_TRUST_STORE_PIN;
081
082
083
084  // The "trust-store-pin-environment-variable" property definition.
085  private static final StringPropertyDefinition PD_TRUST_STORE_PIN_ENVIRONMENT_VARIABLE;
086
087
088
089  // The "trust-store-pin-file" property definition.
090  private static final StringPropertyDefinition PD_TRUST_STORE_PIN_FILE;
091
092
093
094  // The "trust-store-pin-property" property definition.
095  private static final StringPropertyDefinition PD_TRUST_STORE_PIN_PROPERTY;
096
097
098
099  // The "trust-store-type" property definition.
100  private static final StringPropertyDefinition PD_TRUST_STORE_TYPE;
101
102
103
104  // The "writability-mode" property definition.
105  private static final EnumPropertyDefinition<WritabilityMode> PD_WRITABILITY_MODE;
106
107
108
109  // Build the "java-class" property definition.
110  static {
111      ClassPropertyDefinition.Builder builder = ClassPropertyDefinition.createBuilder(INSTANCE, "java-class");
112      builder.setOption(PropertyOption.MANDATORY);
113      builder.setOption(PropertyOption.ADVANCED);
114      builder.setAdministratorAction(new AdministratorAction(AdministratorAction.Type.COMPONENT_RESTART, INSTANCE, "java-class"));
115      DefaultBehaviorProvider<String> provider = new DefinedDefaultBehaviorProvider<String>("org.opends.server.backends.TrustStoreBackend");
116      builder.setDefaultBehaviorProvider(provider);
117      builder.addInstanceOf("org.opends.server.api.Backend");
118      PD_JAVA_CLASS = builder.getInstance();
119      INSTANCE.registerPropertyDefinition(PD_JAVA_CLASS);
120  }
121
122
123
124  // Build the "trust-store-file" property definition.
125  static {
126      StringPropertyDefinition.Builder builder = StringPropertyDefinition.createBuilder(INSTANCE, "trust-store-file");
127      builder.setOption(PropertyOption.MANDATORY);
128      builder.setAdministratorAction(new AdministratorAction(AdministratorAction.Type.NONE, INSTANCE, "trust-store-file"));
129      DefaultBehaviorProvider<String> provider = new DefinedDefaultBehaviorProvider<String>("config/ads-truststore");
130      builder.setDefaultBehaviorProvider(provider);
131      PD_TRUST_STORE_FILE = builder.getInstance();
132      INSTANCE.registerPropertyDefinition(PD_TRUST_STORE_FILE);
133  }
134
135
136
137  // Build the "trust-store-pin" property definition.
138  static {
139      StringPropertyDefinition.Builder builder = StringPropertyDefinition.createBuilder(INSTANCE, "trust-store-pin");
140      builder.setAdministratorAction(new AdministratorAction(AdministratorAction.Type.NONE, INSTANCE, "trust-store-pin"));
141      builder.setDefaultBehaviorProvider(new UndefinedDefaultBehaviorProvider<String>());
142      PD_TRUST_STORE_PIN = builder.getInstance();
143      INSTANCE.registerPropertyDefinition(PD_TRUST_STORE_PIN);
144  }
145
146
147
148  // Build the "trust-store-pin-environment-variable" property definition.
149  static {
150      StringPropertyDefinition.Builder builder = StringPropertyDefinition.createBuilder(INSTANCE, "trust-store-pin-environment-variable");
151      builder.setAdministratorAction(new AdministratorAction(AdministratorAction.Type.NONE, INSTANCE, "trust-store-pin-environment-variable"));
152      builder.setDefaultBehaviorProvider(new UndefinedDefaultBehaviorProvider<String>());
153      PD_TRUST_STORE_PIN_ENVIRONMENT_VARIABLE = builder.getInstance();
154      INSTANCE.registerPropertyDefinition(PD_TRUST_STORE_PIN_ENVIRONMENT_VARIABLE);
155  }
156
157
158
159  // Build the "trust-store-pin-file" property definition.
160  static {
161      StringPropertyDefinition.Builder builder = StringPropertyDefinition.createBuilder(INSTANCE, "trust-store-pin-file");
162      builder.setAdministratorAction(new AdministratorAction(AdministratorAction.Type.NONE, INSTANCE, "trust-store-pin-file"));
163      builder.setDefaultBehaviorProvider(new UndefinedDefaultBehaviorProvider<String>());
164      PD_TRUST_STORE_PIN_FILE = builder.getInstance();
165      INSTANCE.registerPropertyDefinition(PD_TRUST_STORE_PIN_FILE);
166  }
167
168
169
170  // Build the "trust-store-pin-property" property definition.
171  static {
172      StringPropertyDefinition.Builder builder = StringPropertyDefinition.createBuilder(INSTANCE, "trust-store-pin-property");
173      builder.setAdministratorAction(new AdministratorAction(AdministratorAction.Type.NONE, INSTANCE, "trust-store-pin-property"));
174      builder.setDefaultBehaviorProvider(new UndefinedDefaultBehaviorProvider<String>());
175      PD_TRUST_STORE_PIN_PROPERTY = builder.getInstance();
176      INSTANCE.registerPropertyDefinition(PD_TRUST_STORE_PIN_PROPERTY);
177  }
178
179
180
181  // Build the "trust-store-type" property definition.
182  static {
183      StringPropertyDefinition.Builder builder = StringPropertyDefinition.createBuilder(INSTANCE, "trust-store-type");
184      builder.setAdministratorAction(new AdministratorAction(AdministratorAction.Type.NONE, INSTANCE, "trust-store-type"));
185      builder.setDefaultBehaviorProvider(new AliasDefaultBehaviorProvider<String>(INSTANCE, "trust-store-type"));
186      PD_TRUST_STORE_TYPE = builder.getInstance();
187      INSTANCE.registerPropertyDefinition(PD_TRUST_STORE_TYPE);
188  }
189
190
191
192  // Build the "writability-mode" property definition.
193  static {
194      EnumPropertyDefinition.Builder<WritabilityMode> builder = EnumPropertyDefinition.createBuilder(INSTANCE, "writability-mode");
195      builder.setOption(PropertyOption.MANDATORY);
196      builder.setAdministratorAction(new AdministratorAction(AdministratorAction.Type.NONE, INSTANCE, "writability-mode"));
197      DefaultBehaviorProvider<WritabilityMode> provider = new DefinedDefaultBehaviorProvider<WritabilityMode>("enabled");
198      builder.setDefaultBehaviorProvider(provider);
199      builder.setEnumClass(WritabilityMode.class);
200      PD_WRITABILITY_MODE = builder.getInstance();
201      INSTANCE.registerPropertyDefinition(PD_WRITABILITY_MODE);
202  }
203
204
205
206  // Register the options associated with this managed object definition.
207  static {
208    INSTANCE.registerOption(ManagedObjectOption.ADVANCED);
209  }
210
211
212
213  // Register the tags associated with this managed object definition.
214  static {
215    INSTANCE.registerTag(Tag.valueOf("database"));
216  }
217
218
219
220  /**
221   * Get the Trust Store Backend configuration definition singleton.
222   *
223   * @return Returns the Trust Store Backend configuration definition
224   *         singleton.
225   */
226  public static TrustStoreBackendCfgDefn getInstance() {
227    return INSTANCE;
228  }
229
230
231
232  /**
233   * Private constructor.
234   */
235  private TrustStoreBackendCfgDefn() {
236    super("trust-store-backend", BackendCfgDefn.getInstance());
237  }
238
239
240
241  /**
242   * {@inheritDoc}
243   */
244  public TrustStoreBackendCfgClient createClientConfiguration(
245      ManagedObject<? extends TrustStoreBackendCfgClient> impl) {
246    return new TrustStoreBackendCfgClientImpl(impl);
247  }
248
249
250
251  /**
252   * {@inheritDoc}
253   */
254  public TrustStoreBackendCfg createServerConfiguration(
255      ServerManagedObject<? extends TrustStoreBackendCfg> impl) {
256    return new TrustStoreBackendCfgServerImpl(impl);
257  }
258
259
260
261  /**
262   * {@inheritDoc}
263   */
264  public Class<TrustStoreBackendCfg> getServerConfigurationClass() {
265    return TrustStoreBackendCfg.class;
266  }
267
268
269
270  /**
271   * Get the "backend-id" property definition.
272   * <p>
273   * Specifies a name to identify the associated backend.
274   * <p>
275   * The name must be unique among all backends in the server. The
276   * backend ID may not be altered after the backend is created in the
277   * server.
278   *
279   * @return Returns the "backend-id" property definition.
280   */
281  public StringPropertyDefinition getBackendIdPropertyDefinition() {
282    return BackendCfgDefn.getInstance().getBackendIdPropertyDefinition();
283  }
284
285
286
287  /**
288   * Get the "base-dn" property definition.
289   * <p>
290   * Specifies the base DN(s) for the data that the backend handles.
291   * <p>
292   * A single backend may be responsible for one or more base DNs.
293   * Note that no two backends may have the same base DN although one
294   * backend may have a base DN that is below a base DN provided by
295   * another backend (similar to the use of sub-suffixes in the Sun
296   * Java System Directory Server). If any of the base DNs is
297   * subordinate to a base DN for another backend, then all base DNs
298   * for that backend must be subordinate to that same base DN.
299   *
300   * @return Returns the "base-dn" property definition.
301   */
302  public DNPropertyDefinition getBaseDNPropertyDefinition() {
303    return BackendCfgDefn.getInstance().getBaseDNPropertyDefinition();
304  }
305
306
307
308  /**
309   * Get the "enabled" property definition.
310   * <p>
311   * Indicates whether the backend is enabled in the server.
312   * <p>
313   * If a backend is not enabled, then its contents are not accessible
314   * when processing operations.
315   *
316   * @return Returns the "enabled" property definition.
317   */
318  public BooleanPropertyDefinition getEnabledPropertyDefinition() {
319    return BackendCfgDefn.getInstance().getEnabledPropertyDefinition();
320  }
321
322
323
324  /**
325   * Get the "java-class" property definition.
326   * <p>
327   * Specifies the fully-qualified name of the Java class that
328   * provides the backend implementation.
329   *
330   * @return Returns the "java-class" property definition.
331   */
332  public ClassPropertyDefinition getJavaClassPropertyDefinition() {
333    return PD_JAVA_CLASS;
334  }
335
336
337
338  /**
339   * Get the "trust-store-file" property definition.
340   * <p>
341   * Specifies the path to the file that stores the trust information.
342   * <p>
343   * It may be an absolute path, or a path that is relative to the
344   * OpenDJ instance root.
345   *
346   * @return Returns the "trust-store-file" property definition.
347   */
348  public StringPropertyDefinition getTrustStoreFilePropertyDefinition() {
349    return PD_TRUST_STORE_FILE;
350  }
351
352
353
354  /**
355   * Get the "trust-store-pin" property definition.
356   * <p>
357   * Specifies the clear-text PIN needed to access the Trust Store
358   * Backend .
359   *
360   * @return Returns the "trust-store-pin" property definition.
361   */
362  public StringPropertyDefinition getTrustStorePinPropertyDefinition() {
363    return PD_TRUST_STORE_PIN;
364  }
365
366
367
368  /**
369   * Get the "trust-store-pin-environment-variable" property definition.
370   * <p>
371   * Specifies the name of the environment variable that contains the
372   * clear-text PIN needed to access the Trust Store Backend .
373   *
374   * @return Returns the "trust-store-pin-environment-variable" property definition.
375   */
376  public StringPropertyDefinition getTrustStorePinEnvironmentVariablePropertyDefinition() {
377    return PD_TRUST_STORE_PIN_ENVIRONMENT_VARIABLE;
378  }
379
380
381
382  /**
383   * Get the "trust-store-pin-file" property definition.
384   * <p>
385   * Specifies the path to the text file whose only contents should be
386   * a single line containing the clear-text PIN needed to access the
387   * Trust Store Backend .
388   *
389   * @return Returns the "trust-store-pin-file" property definition.
390   */
391  public StringPropertyDefinition getTrustStorePinFilePropertyDefinition() {
392    return PD_TRUST_STORE_PIN_FILE;
393  }
394
395
396
397  /**
398   * Get the "trust-store-pin-property" property definition.
399   * <p>
400   * Specifies the name of the Java property that contains the
401   * clear-text PIN needed to access the Trust Store Backend .
402   *
403   * @return Returns the "trust-store-pin-property" property definition.
404   */
405  public StringPropertyDefinition getTrustStorePinPropertyPropertyDefinition() {
406    return PD_TRUST_STORE_PIN_PROPERTY;
407  }
408
409
410
411  /**
412   * Get the "trust-store-type" property definition.
413   * <p>
414   * Specifies the format for the data in the key store file.
415   * <p>
416   * Valid values should always include 'JKS' and 'PKCS12', but
417   * different implementations may allow other values as well.
418   *
419   * @return Returns the "trust-store-type" property definition.
420   */
421  public StringPropertyDefinition getTrustStoreTypePropertyDefinition() {
422    return PD_TRUST_STORE_TYPE;
423  }
424
425
426
427  /**
428   * Get the "writability-mode" property definition.
429   * <p>
430   * Specifies the behavior that the backend should use when
431   * processing write operations.
432   *
433   * @return Returns the "writability-mode" property definition.
434   */
435  public EnumPropertyDefinition<WritabilityMode> getWritabilityModePropertyDefinition() {
436    return PD_WRITABILITY_MODE;
437  }
438
439
440
441  /**
442   * Managed object client implementation.
443   */
444  private static class TrustStoreBackendCfgClientImpl implements
445    TrustStoreBackendCfgClient {
446
447    // Private implementation.
448    private ManagedObject<? extends TrustStoreBackendCfgClient> impl;
449
450
451
452    // Private constructor.
453    private TrustStoreBackendCfgClientImpl(
454        ManagedObject<? extends TrustStoreBackendCfgClient> impl) {
455      this.impl = impl;
456    }
457
458
459
460    /**
461     * {@inheritDoc}
462     */
463    public String getBackendId() {
464      return impl.getPropertyValue(INSTANCE.getBackendIdPropertyDefinition());
465    }
466
467
468
469    /**
470     * {@inheritDoc}
471     */
472    public void setBackendId(String value) throws PropertyException {
473      impl.setPropertyValue(INSTANCE.getBackendIdPropertyDefinition(), value);
474    }
475
476
477
478    /**
479     * {@inheritDoc}
480     */
481    public SortedSet<DN> getBaseDN() {
482      return impl.getPropertyValues(INSTANCE.getBaseDNPropertyDefinition());
483    }
484
485
486
487    /**
488     * {@inheritDoc}
489     */
490    public void setBaseDN(Collection<DN> values) {
491      impl.setPropertyValues(INSTANCE.getBaseDNPropertyDefinition(), values);
492    }
493
494
495
496    /**
497     * {@inheritDoc}
498     */
499    public Boolean isEnabled() {
500      return impl.getPropertyValue(INSTANCE.getEnabledPropertyDefinition());
501    }
502
503
504
505    /**
506     * {@inheritDoc}
507     */
508    public void setEnabled(boolean value) {
509      impl.setPropertyValue(INSTANCE.getEnabledPropertyDefinition(), value);
510    }
511
512
513
514    /**
515     * {@inheritDoc}
516     */
517    public String getJavaClass() {
518      return impl.getPropertyValue(INSTANCE.getJavaClassPropertyDefinition());
519    }
520
521
522
523    /**
524     * {@inheritDoc}
525     */
526    public void setJavaClass(String value) {
527      impl.setPropertyValue(INSTANCE.getJavaClassPropertyDefinition(), value);
528    }
529
530
531
532    /**
533     * {@inheritDoc}
534     */
535    public String getTrustStoreFile() {
536      return impl.getPropertyValue(INSTANCE.getTrustStoreFilePropertyDefinition());
537    }
538
539
540
541    /**
542     * {@inheritDoc}
543     */
544    public void setTrustStoreFile(String value) {
545      impl.setPropertyValue(INSTANCE.getTrustStoreFilePropertyDefinition(), value);
546    }
547
548
549
550    /**
551     * {@inheritDoc}
552     */
553    public String getTrustStorePin() {
554      return impl.getPropertyValue(INSTANCE.getTrustStorePinPropertyDefinition());
555    }
556
557
558
559    /**
560     * {@inheritDoc}
561     */
562    public void setTrustStorePin(String value) {
563      impl.setPropertyValue(INSTANCE.getTrustStorePinPropertyDefinition(), value);
564    }
565
566
567
568    /**
569     * {@inheritDoc}
570     */
571    public String getTrustStorePinEnvironmentVariable() {
572      return impl.getPropertyValue(INSTANCE.getTrustStorePinEnvironmentVariablePropertyDefinition());
573    }
574
575
576
577    /**
578     * {@inheritDoc}
579     */
580    public void setTrustStorePinEnvironmentVariable(String value) {
581      impl.setPropertyValue(INSTANCE.getTrustStorePinEnvironmentVariablePropertyDefinition(), value);
582    }
583
584
585
586    /**
587     * {@inheritDoc}
588     */
589    public String getTrustStorePinFile() {
590      return impl.getPropertyValue(INSTANCE.getTrustStorePinFilePropertyDefinition());
591    }
592
593
594
595    /**
596     * {@inheritDoc}
597     */
598    public void setTrustStorePinFile(String value) {
599      impl.setPropertyValue(INSTANCE.getTrustStorePinFilePropertyDefinition(), value);
600    }
601
602
603
604    /**
605     * {@inheritDoc}
606     */
607    public String getTrustStorePinProperty() {
608      return impl.getPropertyValue(INSTANCE.getTrustStorePinPropertyPropertyDefinition());
609    }
610
611
612
613    /**
614     * {@inheritDoc}
615     */
616    public void setTrustStorePinProperty(String value) {
617      impl.setPropertyValue(INSTANCE.getTrustStorePinPropertyPropertyDefinition(), value);
618    }
619
620
621
622    /**
623     * {@inheritDoc}
624     */
625    public String getTrustStoreType() {
626      return impl.getPropertyValue(INSTANCE.getTrustStoreTypePropertyDefinition());
627    }
628
629
630
631    /**
632     * {@inheritDoc}
633     */
634    public void setTrustStoreType(String value) {
635      impl.setPropertyValue(INSTANCE.getTrustStoreTypePropertyDefinition(), value);
636    }
637
638
639
640    /**
641     * {@inheritDoc}
642     */
643    public WritabilityMode getWritabilityMode() {
644      return impl.getPropertyValue(INSTANCE.getWritabilityModePropertyDefinition());
645    }
646
647
648
649    /**
650     * {@inheritDoc}
651     */
652    public void setWritabilityMode(WritabilityMode value) {
653      impl.setPropertyValue(INSTANCE.getWritabilityModePropertyDefinition(), value);
654    }
655
656
657
658    /**
659     * {@inheritDoc}
660     */
661    public ManagedObjectDefinition<? extends TrustStoreBackendCfgClient, ? extends TrustStoreBackendCfg> definition() {
662      return INSTANCE;
663    }
664
665
666
667    /**
668     * {@inheritDoc}
669     */
670    public PropertyProvider properties() {
671      return impl;
672    }
673
674
675
676    /**
677     * {@inheritDoc}
678     */
679    public void commit() throws ManagedObjectAlreadyExistsException,
680        MissingMandatoryPropertiesException, ConcurrentModificationException,
681        OperationRejectedException, AuthorizationException,
682        CommunicationException {
683      impl.commit();
684    }
685
686
687
688    /** {@inheritDoc} */
689    public String toString() {
690      return impl.toString();
691    }
692  }
693
694
695
696  /**
697   * Managed object server implementation.
698   */
699  private static class TrustStoreBackendCfgServerImpl implements
700    TrustStoreBackendCfg {
701
702    // Private implementation.
703    private ServerManagedObject<? extends TrustStoreBackendCfg> impl;
704
705    // The value of the "backend-id" property.
706    private final String pBackendId;
707
708    // The value of the "base-dn" property.
709    private final SortedSet<DN> pBaseDN;
710
711    // The value of the "enabled" property.
712    private final boolean pEnabled;
713
714    // The value of the "java-class" property.
715    private final String pJavaClass;
716
717    // The value of the "trust-store-file" property.
718    private final String pTrustStoreFile;
719
720    // The value of the "trust-store-pin" property.
721    private final String pTrustStorePin;
722
723    // The value of the "trust-store-pin-environment-variable" property.
724    private final String pTrustStorePinEnvironmentVariable;
725
726    // The value of the "trust-store-pin-file" property.
727    private final String pTrustStorePinFile;
728
729    // The value of the "trust-store-pin-property" property.
730    private final String pTrustStorePinProperty;
731
732    // The value of the "trust-store-type" property.
733    private final String pTrustStoreType;
734
735    // The value of the "writability-mode" property.
736    private final WritabilityMode pWritabilityMode;
737
738
739
740    // Private constructor.
741    private TrustStoreBackendCfgServerImpl(ServerManagedObject<? extends TrustStoreBackendCfg> impl) {
742      this.impl = impl;
743      this.pBackendId = impl.getPropertyValue(INSTANCE.getBackendIdPropertyDefinition());
744      this.pBaseDN = impl.getPropertyValues(INSTANCE.getBaseDNPropertyDefinition());
745      this.pEnabled = impl.getPropertyValue(INSTANCE.getEnabledPropertyDefinition());
746      this.pJavaClass = impl.getPropertyValue(INSTANCE.getJavaClassPropertyDefinition());
747      this.pTrustStoreFile = impl.getPropertyValue(INSTANCE.getTrustStoreFilePropertyDefinition());
748      this.pTrustStorePin = impl.getPropertyValue(INSTANCE.getTrustStorePinPropertyDefinition());
749      this.pTrustStorePinEnvironmentVariable = impl.getPropertyValue(INSTANCE.getTrustStorePinEnvironmentVariablePropertyDefinition());
750      this.pTrustStorePinFile = impl.getPropertyValue(INSTANCE.getTrustStorePinFilePropertyDefinition());
751      this.pTrustStorePinProperty = impl.getPropertyValue(INSTANCE.getTrustStorePinPropertyPropertyDefinition());
752      this.pTrustStoreType = impl.getPropertyValue(INSTANCE.getTrustStoreTypePropertyDefinition());
753      this.pWritabilityMode = impl.getPropertyValue(INSTANCE.getWritabilityModePropertyDefinition());
754    }
755
756
757
758    /**
759     * {@inheritDoc}
760     */
761    public void addTrustStoreChangeListener(
762        ConfigurationChangeListener<TrustStoreBackendCfg> listener) {
763      impl.registerChangeListener(listener);
764    }
765
766
767
768    /**
769     * {@inheritDoc}
770     */
771    public void removeTrustStoreChangeListener(
772        ConfigurationChangeListener<TrustStoreBackendCfg> listener) {
773      impl.deregisterChangeListener(listener);
774    }
775    /**
776     * {@inheritDoc}
777     */
778    public void addChangeListener(
779        ConfigurationChangeListener<BackendCfg> listener) {
780      impl.registerChangeListener(listener);
781    }
782
783
784
785    /**
786     * {@inheritDoc}
787     */
788    public void removeChangeListener(
789        ConfigurationChangeListener<BackendCfg> listener) {
790      impl.deregisterChangeListener(listener);
791    }
792
793
794
795    /**
796     * {@inheritDoc}
797     */
798    public String getBackendId() {
799      return pBackendId;
800    }
801
802
803
804    /**
805     * {@inheritDoc}
806     */
807    public SortedSet<DN> getBaseDN() {
808      return pBaseDN;
809    }
810
811
812
813    /**
814     * {@inheritDoc}
815     */
816    public boolean isEnabled() {
817      return pEnabled;
818    }
819
820
821
822    /**
823     * {@inheritDoc}
824     */
825    public String getJavaClass() {
826      return pJavaClass;
827    }
828
829
830
831    /**
832     * {@inheritDoc}
833     */
834    public String getTrustStoreFile() {
835      return pTrustStoreFile;
836    }
837
838
839
840    /**
841     * {@inheritDoc}
842     */
843    public String getTrustStorePin() {
844      return pTrustStorePin;
845    }
846
847
848
849    /**
850     * {@inheritDoc}
851     */
852    public String getTrustStorePinEnvironmentVariable() {
853      return pTrustStorePinEnvironmentVariable;
854    }
855
856
857
858    /**
859     * {@inheritDoc}
860     */
861    public String getTrustStorePinFile() {
862      return pTrustStorePinFile;
863    }
864
865
866
867    /**
868     * {@inheritDoc}
869     */
870    public String getTrustStorePinProperty() {
871      return pTrustStorePinProperty;
872    }
873
874
875
876    /**
877     * {@inheritDoc}
878     */
879    public String getTrustStoreType() {
880      return pTrustStoreType;
881    }
882
883
884
885    /**
886     * {@inheritDoc}
887     */
888    public WritabilityMode getWritabilityMode() {
889      return pWritabilityMode;
890    }
891
892
893
894    /**
895     * {@inheritDoc}
896     */
897    public Class<? extends TrustStoreBackendCfg> configurationClass() {
898      return TrustStoreBackendCfg.class;
899    }
900
901
902
903    /**
904     * {@inheritDoc}
905     */
906    public DN dn() {
907      return impl.getDN();
908    }
909
910
911
912    /** {@inheritDoc} */
913    public String toString() {
914      return impl.toString();
915    }
916  }
917}