View Javadoc

1   package com.sun.syndication.common;
2   
3   /***
4    * @author Alejandro Abdelnur
5    */
6   public interface CopyFrom {
7   
8       /***
9        * Returns the interface the copyFrom works on.
10       * <p>
11       * This is useful when dealing with properties that may have multiple implementations.
12       * For example, ModuleI.
13       * <p>
14       * @return the interface the copyFrom works on.
15       */
16      public Class getInterface();
17  
18      /***
19       * Copies all the properties of the given bean into this one.
20       * <p>
21       * Any existing properties in this bean are lost.
22       * <p>
23       * This method is useful for moving from one implementation of a bean interface to another.
24       * For example from the default SyndFeedI bean implementation to a Hibernate ready implementation.
25       * <p>
26       * @param obj the instance to copy properties from.
27       *
28       */
29      public void copyFrom(Object obj);
30  
31  }