Test class for Spring.NET's ability to create objects using static factory methods, rather than constructors.
예제 #1
0
        public FactoryMethods DefaultInstance()
        {
            TestObject to = new TestObject();

            to.Name = FactoryObjectProperty;
            return(FactoryMethods.NewInstance(to));
        }
예제 #2
0
 public FactoryMethods CreateInstance(IDataRecord dr)
 {
     return(FactoryMethods.NewInstance(new TestObject(), "DataRecordCtor", 0));
 }
예제 #3
0
 public FactoryMethods CreateInstance()
 {
     return(FactoryMethods.NewInstance(new TestObject(), "DefaultCtor", 0));
 }
예제 #4
0
 public FactoryMethods NewInstance(TestObject to, int num, string name)
 {
     return(FactoryMethods.NewInstance(to, name, num));
 }
예제 #5
0
 /// <summary>
 /// Note that overloaded methods are supported.
 /// </summary>
 public FactoryMethods NewInstance(TestObject to)
 {
     return(FactoryMethods.NewInstance(to));
 }