Clone() public method

public Clone ( ) : object
return object
示例#1
0
 public virtual void AddCertPathChecker(PkixCertPathChecker checker)
 {
     if (checker != null)
     {
         this.certPathCheckers.Add(checker.Clone());
     }
 }
示例#2
0
 public virtual void SetCertPathCheckers(global::System.Collections.IList checkers)
 {
     certPathCheckers = Platform.CreateArrayList();
     if (checkers == null)
     {
         return;
     }
     global::System.Collections.IEnumerator enumerator = ((global::System.Collections.IEnumerable)checkers).GetEnumerator();
     try
     {
         while (enumerator.MoveNext())
         {
             PkixCertPathChecker pkixCertPathChecker = (PkixCertPathChecker)enumerator.get_Current();
             certPathCheckers.Add(pkixCertPathChecker.Clone());
         }
     }
     finally
     {
         global::System.IDisposable disposable = enumerator as global::System.IDisposable;
         if (disposable != null)
         {
             disposable.Dispose();
         }
     }
 }
示例#3
0
 public virtual global::System.Collections.IList GetCertPathCheckers()
 {
     global::System.Collections.IList       list       = Platform.CreateArrayList();
     global::System.Collections.IEnumerator enumerator = ((global::System.Collections.IEnumerable)certPathCheckers).GetEnumerator();
     try
     {
         while (enumerator.MoveNext())
         {
             PkixCertPathChecker pkixCertPathChecker = (PkixCertPathChecker)enumerator.get_Current();
             list.Add(pkixCertPathChecker.Clone());
         }
         return(list);
     }
     finally
     {
         global::System.IDisposable disposable = enumerator as global::System.IDisposable;
         if (disposable != null)
         {
             disposable.Dispose();
         }
     }
 }
		/**
		 * Adds a <code>PKIXCertPathChecker</code> to the list of certification
		 * path checkers. See the {@link #setCertPathCheckers setCertPathCheckers}
		 * method for more details.
		 * <p>
		 * Note that the <code>PKIXCertPathChecker</code> is cloned to protect
		 * against subsequent modifications.</p>
		 *
		 * @param checker a <code>PKIXCertPathChecker</code> to add to the list of
		 * checks. If <code>null</code>, the checker is ignored (not added to list).
		 */
		public virtual void AddCertPathChecker(
			PkixCertPathChecker checker)
		{
			if (checker != null)
			{
				certPathCheckers.Add(checker.Clone());
			}
		}