// Path: src/main/java/com/versionone/integration/ciCommon/VcsModification.java
// public interface VcsModification {
// 
//     String getUserName();
// 
//     String getComment();
// 
//     /**
//      * Get modification date.
//      *
//      * @return Date and time the modification occur. Or null.
//      */
//     Date getDate();
// 
//     String getId();
// }


import hudson.scm.ChangeLogSet;
import java.lang.reflect.Constructor;
import java.util.HashMap;
import java.util.Map;
import com.versionone.integration.ciCommon.VcsModification;
                              "com.versionone.jenkins.GitModification");

        fillSupportedMappings();
    }

    private void fillSupportedMappings() {
        for(Map.Entry<String, String> entry : classNameMappings.entrySet()) {
            try {
                Class logEntryClass = Class.forName(entry.getKey());
                Class wrapperClass = Class.forName(entry.getValue());
                mappings.put(logEntryClass, wrapperClass);
            } catch(ClassNotFoundException e) {
                // do nothing, it is an unsupported VCS changeset type
            	e.printStackTrace();
            }
        }
    }

    public static VcsModificationWrapperFactory getInstance() {
        if(instance == null) {
            instance = new VcsModificationWrapperFactory();
        }

        return instance;
    }

    public boolean isSupported(ChangeLogSet.Entry modification) {
        return modification != null && mappings.containsKey(modification.getClass());
    }

// Path: src/main/java/com/versionone/integration/ciCommon/VcsModification.java
// public interface VcsModification {
// 
//     String getUserName();
// 
//     String getComment();
// 
//     /**
//      * Get modification date.
//      *
//      * @return Date and time the modification occur. Or null.
//      */
//     Date getDate();
// 
//     String getId();
// }


// Path: src/main/java/com/versionone/jenkins/VcsModificationWrapperFactory.java
import hudson.scm.ChangeLogSet;
import java.lang.reflect.Constructor;
import java.util.HashMap;
import java.util.Map;
import com.versionone.integration.ciCommon.VcsModification;

                              "com.versionone.jenkins.GitModification");

        fillSupportedMappings();
    }

    private void fillSupportedMappings() {
        for(Map.Entry<String, String> entry : classNameMappings.entrySet()) {
            try {
                Class logEntryClass = Class.forName(entry.getKey());
                Class wrapperClass = Class.forName(entry.getValue());
                mappings.put(logEntryClass, wrapperClass);
            } catch(ClassNotFoundException e) {
                // do nothing, it is an unsupported VCS changeset type
            	e.printStackTrace();
            }
        }
    }

    public static VcsModificationWrapperFactory getInstance() {
        if(instance == null) {
            instance = new VcsModificationWrapperFactory();
        }

        return instance;
    }

    public boolean isSupported(ChangeLogSet.Entry modification) {
        return modification != null && mappings.containsKey(modification.getClass());
    }

    public VcsModification createWrapper(ChangeLogSet.Entry modification) {