/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package messerviceframeworkri;

import com.essar.mes.service.framework.annotations.ErrorResult;
import java.lang.reflect.Method;

/**
 *
 * @author dhaval
 */
public class AnnotationTest {

    /**
     * @param args the command line arguments
     */
    public static void main(String[] args) {
        TestClass tc = new TestClass();
        Method[] methods = tc.getClass().getDeclaredMethods();
        for(Method method : methods){
            if(method.isAnnotationPresent(ErrorResult.class)){
                System.out.println("method found, " + method);
            }
        }
    }

    public static class TestClass{

//        @ErrorResult(service="test")
        public String getString(){
            return "hello, world";
        }
    }
}
