Myeclipse Subscription key generator for 6.0 - 9.0

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.Calendar;

public class MyEclipseKeyGen {
    private static final String LL = "Decompiling this copyrighted software is a violation of both your license agreement and the Digital Millenium Copyright Act of 1998 (http://www.loc.gov/copyright/legislation/dmca.pdf). Under section 1204 of the DMCA, penalties range up to a $500,000 fine or up to five years imprisonment for a first offense. Think about it; pay for a license, avoid prosecution, and feel better about yourself.";

    public String getSerial(String userId, String licenseNum, String type) {
        java.util.Calendar cal = java.util.Calendar.getInstance();
        cal.add(Calendar.DAY_OF_MONTH, 1000);
        //cal.add(6, -1);
        java.text.NumberFormat nf = new java.text.DecimalFormat("000");
        licenseNum = nf.format(Integer.valueOf(licenseNum));
        String verTime = new StringBuilder("-").append(
                new java.text.SimpleDateFormat("yyMMdd").format(cal.getTime()))
                .append("0").toString();
        String need = new StringBuilder(userId.substring(0, 1)).append(type)
                .append("300").append(licenseNum).append(verTime).toString();
        String dx = new StringBuilder(need).append(MyEclipseKeyGen.LL).append(
                userId).toString();
        int suf = this.decode(dx);
        String code = new StringBuilder(need).append(String.valueOf(suf))
                .toString();
        return this.change(code);
    }

    private int decode(String s) {
        int i;
        char[] ac;
        int j;
        int k;
        i = 0;
        ac = s.toCharArray();
        j = 0;
        k = ac.length;
        while (j < k) {
            i = (31 * i) + ac[j];
            j++;
        }
        return Math.abs(i);
    }

    private String change(String s) {
        byte[] abyte0;
        char[] ac;
        int i;
        int k;
        int j;
        abyte0 = s.getBytes();
        ac = new char[s.length()];
        i = 0;
        k = abyte0.length;
        while (i < k) {
            j = abyte0[i];
            if ((j >= 48) && (j <= 57)) {
                j = (((j - 48) + 5) % 10) + 48;

            } else if ((j >= 65) && (j <= 90)) {
                j = (((j - 65) + 13) % 26) + 65;

            } else if ((j >= 97) && (j <= 122)) {
                j = (((j - 97) + 13) % 26) + 97;
            }
            ac[i] = (char) j;
            i++;
        }
        return String.valueOf(ac);
    }

    public MyEclipseKeyGen() {
        super();
    }

    public static void main(String[] args) {
        try {
            // MyEclipse Standard Subscription --------- YE2MY
            // MyEclipse Professional Subscription ---- YE3MP
            // MyEclipse Blue Subscription --------------- YE3MB
            // MyEclipse for Spring Subscription -------- YE3MS
            String type = "YE3MB-";
            // for the local version of String type ="YE3MP-";//??????
            System.out.println("please input register name:");
            BufferedReader reader = new BufferedReader(new InputStreamReader(
                    System.in));
            String userId = null;
            userId = reader.readLine();
            MyEclipseKeyGen myeclipsegen = new MyEclipseKeyGen();
            String res = myeclipsegen.getSerial(userId, "5", type);
            System.out.println("Serial:" + res);
            reader.readLine();
        } catch (IOException ex) {
        }
    }

}

Samsung S5620 Flash Guide


What to do first:
1) Save everything.
2) Take out SIM card.
3) Take out Micro SD.

What you need:
1) Firmware.
2) Flash program.
3) Flash cable (Original USB cable)
4) Your phone: S5620.

Lets start.
1) Start with a hard rest for safety. (code *2767*3855#)
2) Check your firmware (Code *#1234#)
3) Check our firmware list and download a firmware you want. (We use S5620XEJD1)
4) Download the flash program. (Multiloader v5.62!) (Find this on our S5620 page)
5) Unrar the firmware.
6) Unrar the program.
7) Into the Firmware you will see three files. (Our ReadMe, CSC and CODE)
8) Open the multiloader. (Set a check by BRCM2153)
9) Set a check by Boot Change.
10) Click on Boot and go to the Boot file and click.
11) Set in multiloader a check by All Download.
12) click on Amss and go to the file.
13) Do the same by Rsrc1, Rsrc2, Factory FS, CSC, SHP SPP and PFS.
14) NOTE select by RSRC2 always the LOW version!
15) NOTE check FFS and PFS on the same region. (We use SER)

16) Take you USB cable.
17) Take your phone.
18) Put your phone in Download MODE.(Sound Key Down + Camera + Power On) (Make sure your phone is out before)
19) You will seen now: DOWNLOAD MODE or ALL DOWNLOAD or BOOT change.
gt-s5620

Spring MVC - AnnotationController

Person.java
------------------------------

package com.anil.domain;

public class Person {

    private String name;
    private int age;

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public int getAge() {
        return age;
    }

    public void setAge(int age) {
        this.age = age;
    }

}
-----------------------------------------------
PersonService.java
----------------------------------------------
package com.anil.service;

import com.anil.domain.Person;

public interface PersonService {

    public void add(Person person);
}
---------------------------------------------
PersonServiceImpl.java
--------------------------------------------
package com.anil.service;

import com.anil.domain.Person;

public class PersonServiceImpl implements PersonService {

    public void add(Person anil) {
        //Persist the user object here.
        System.out.println("Person added successfully");

    }

}
-------------------------------------------------------------
PersonController.java
-------------------------------------------------------------
package com.anil.web;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.ModelAttribute;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.SessionAttributes;

import com.anil.domain.Person;
import com.anil.service.PersonService;

@Controller
@RequestMapping("/personRegistration.htm")
@SessionAttributes("person")
public class PersonController {

    private PersonService personService;

    @Autowired
    public void setPersonService(PersonService personService) {
        this.personService = personService;
    }
   
    @RequestMapping(method = RequestMethod.GET)
    public String showPersonForm(ModelMap model)
    {
        Person p = new Person();
        model.addAttribute(p);
        return "personForm";
    }

    @RequestMapping(method = RequestMethod.POST)
    public String onSubmit(@ModelAttribute("person") Person person) {
        personService.add(person);
        return "redirect:personSuccess.htm";
    }
   
}
----------------------------------------------------------------------------
PersonSuccessController.java
---------------------------------------------------------------------------
package com.anil.web;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;

@Controller
public class PersonSuccessController {

    @RequestMapping("/personSuccess.htm")
    public String redirect()
    {
        return "personSuccess";
    }
}
---------------------------------------------------------------------------
PersonForm.jsp
---------------------------------------------------------------------------
<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
    pageEncoding="ISO-8859-1"%>
<%@ taglib uri="http://www.springframework.org/tags/form" prefix="form"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
    <head>
        <meta http-equiv="Content-Type"
            content="text/html; charset=ISO-8859-1">
        <title>Registration Page</title>
    </head>
    <body>

        <form:form method="POST" commandName="person">
            <table>
                <tr>
                    <td>
                        Person Name :
                    </td>
                    <td>
                        <form:input path="name" />
                    </td>
                </tr>
                <tr>
                    <td>
                        Age :
                    </td>
                    <td>
                        <form:input path="age" />
                    </td>
                </tr>
                <tr>
                    <td colspan="2">
                        <input type="submit">
                    </td>
                </tr>
            </table>
        </form:form>

    </body>
</html>
----------------------------------------------------------------
personSucceess.jsp
----------------------------------------------------------------
<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
    pageEncoding="ISO-8859-1"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Success Page</title>
</head>
<body>
Person Details
<hr>
User Name   : ${person.name} <br/>
Age      : ${person.age} <br/>

</body>
</html>
---------------------------------------------------------------------------------------
anil-servlet.xml
---------------------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:p="http://www.springframework.org/schema/p"
    xmlns:context="http://www.springframework.org/schema/context"
    xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
        http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context.xsd">


    <bean id="viewResolver"
        class="org.springframework.web.servlet.view.InternalResourceViewResolver"
        p:prefix="/WEB-INF/jsp/" p:suffix=".jsp" />


    <bean id="personService" class="com.anil.service.PersonServiceImpl" />

    <context:component-scan base-package="com.anil.web" />

    <bean class="org.springframework.web.servlet.mvc.annotation.DefaultAnnotationHandlerMapping" />

    <bean class="org.springframework.web.servlet.mvc.annotation.AnnotationMethodHandlerAdapter" />

</beans>
------------------------------------------------------------------------------------------------------------
web.xml
-------------------------------------------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xmlns="http://java.sun.com/xml/ns/javaee" xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
    xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
    id="WebApp_ID" version="2.5">
    <display-name>SpringExample11</display-name>
    <servlet>
        <servlet-name>anil</servlet-name>
        <servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
        <load-on-startup>1</load-on-startup>
    </servlet>
    <servlet-mapping>
        <servlet-name>anil</servlet-name>
        <url-pattern>*.htm</url-pattern>
    </servlet-mapping>
    <welcome-file-list>
        <welcome-file>index.jsp</welcome-file>
    </welcome-file-list>
</web-app>
--------------------------------------------------------------------------------------------------------------
index.jsp
--------------------------------------------------------------------------------------------------------------
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<% response.sendRedirect("personRegistration.htm"); %>

Spring MVC - SimpleForm Controller

Person.java
-------------------------------------------------------------------------------------------------------------
package com.anil;

public class Person {
    String name;
    int age;

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public int getAge() {
        return age;
    }

    public void setAge(int age) {
        this.age = age;
    }

}
------------------------------------------------------------------------------------------------------------
PersonManagement.java
------------------------------------------------------------------------------------------------------------

package com.anil;

public interface PersonManagement {

    public void displayPerson();
}
------------------------------------------------------------------------------------------------------------
PersonManagementImp.java

-----------------------------------------------------------------------------------------------------------
package com.anil;

public class PersonManagementImpl implements PersonManagement {

    public void displayPerson() {
        Person p=new Person();
        p.setName("Anil");
        p.setAge(27);
        System.out.println("Name : "+p.getName()+" Age : "+p.getAge());

    }

}
---------------------------------------------------------------------------------------------------------------
SimpleFormCon.java
---------------------------------------------------------------------------------------------------------------
package com.anil;

import org.springframework.web.servlet.ModelAndView;
import org.springframework.web.servlet.mvc.SimpleFormController;

@SuppressWarnings("deprecation")
public class SimpleFormCon extends SimpleFormController{

    private PersonManagement personService;
   
        public SimpleFormCon() {
            setCommandClass(Person.class);
            setCommandName("person");
        }
        
        public void setPersonManagement(PersonManagement personService) {
            this.personService = personService;
        }
   
        @Override
        protected ModelAndView onSubmit(Object command) throws Exception {
            Person person = (Person) command;
            personService.displayPerson();
            return new ModelAndView("displayPerson","person",person);
        }
   
   
   
}
---------------------------------------------------------------------------------------------------------------
personMng.jsp
---------------------------------------------------------------------------------------------------------------

<%@ taglib uri="http://www.springframework.org/tags/form" prefix="form"%>
<%@ page language="java" import="java.util.*" pageEncoding="ISO-8859-1"%>
<%
    String path = request.getContextPath();
    String basePath = request.getScheme() + "://"
            + request.getServerName() + ":" + request.getServerPort()
            + path + "/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
    <head>
        <base href="<%=basePath%>">

        <title>My JSP 'personMng.jsp' starting page</title>

        <meta http-equiv="pragma" content="no-cache">
        <meta http-equiv="cache-control" content="no-cache">
        <meta http-equiv="expires" content="0">
        <meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
        <meta http-equiv="description" content="This is my page">
        <!--
    <link rel="stylesheet" type="text/css" href="styles.css">
    -->

    </head>

    <body>
        <form:form method="POST" commandName="person">
            <table>
                <tr>
                    <td>
                        User Name :
                    </td>
                    <td>
                        <form:input path="name" />
                    </td>
                </tr>
                <tr>
                    <td>
                        Age :
                    </td>
                    <td>
                        <form:input path="age" />
                    </td>
                </tr>
                <tr>
                    <td colspan="2">
                        <input type="submit">
                    </td>
                </tr>
            </table>
        </form:form>
    </body>
</html>
--------------------------------------------------------------------------------------------------------------
displayPerson.java
--------------------------------------------------------------------------------------------------------------
<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
    pageEncoding="ISO-8859-1"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Success Page</title>
</head>
<body>
Person Details
<hr>
User Name   : ${person.name} <br/>
Age      : ${person.age} <br/>
</body>
</html>
-------------------------------------------------------------------------------------------------------------
index.jsp
-------------------------------------------------------------------------------------------------------------
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<%-- response.sendRedirect("welcome.htm"); --%>
<% response.sendRedirect("personMng.htm"); %>
-------------------------------------------------------------------------------------------------------------
anil-servlet.xml
-------------------------------------------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:p="http://www.springframework.org/schema/p"
    xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd">
    <bean id="viewResolver"
        class="org.springframework.web.servlet.view.InternalResourceViewResolver">
        <property name="prefix">
            <value>/WEB-INF/jsp/</value>
        </property>
        <property name="suffix">
            <value>.jsp</value>
        </property>
    </bean>
    <bean name="personService" class="com.anil.PersonManagementImpl"></bean>
    <bean name="/personMng.htm" class="com.anil.SimpleFormCon"
        p:personManagement-ref="personService" p:formView="personMng" p:successView="displayPerson" />
</beans>
---------------------------------------------------------------------------------------------------------------
web.xml
---------------------------------------------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8"?>
<web-app version="2.5" xmlns="http://java.sun.com/xml/ns/javaee"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
    http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">

    <servlet>
        <servlet-name>anil</servlet-name>
        <servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
        <load-on-startup>1</load-on-startup>
    </servlet>
    <servlet-mapping>

        <servlet-name>anil</servlet-name>
        <url-pattern>*.htm</url-pattern>
    </servlet-mapping>

    <welcome-file-list>
        <welcome-file>index.jsp</welcome-file>
    </welcome-file-list>
</web-app>
--------------------------------------------------------------------------------------------------------------
pom.xml
--------------------------------------------------------------------------------------------------------------
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
  <modelVersion>4.0.0</modelVersion>
  <groupId>SpringAbstractControlleer</groupId>
  <artifactId>SpringAbstractControlleer</artifactId>
  <version>0.0.1-SNAPSHOT</version>
  <packaging>war</packaging>
  <name/>
  <description/>
  <dependencies>
    <dependency>
      <groupId>org.apache.openejb</groupId>
      <artifactId>javaee-api</artifactId>
      <version>5.0-1</version>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>javax.faces</groupId>
      <artifactId>jsf-api</artifactId>
      <version>1.2_04</version>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>javax.servlet</groupId>
      <artifactId>jstl</artifactId>
      <version>1.2</version>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>javax.servlet.jsp</groupId>
      <artifactId>jsp-api</artifactId>
      <version>2.1</version>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>javax.faces</groupId>
      <artifactId>jsf-impl</artifactId>
      <version>1.2_04</version>
      <scope>provided</scope>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-core</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-beans</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-asm</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>commons-logging</groupId>
        <artifactId>commons-logging</artifactId>
        <version>1.1.1</version>
    </dependency>
    <dependency>
        <groupId>log4j</groupId>
        <artifactId>log4j</artifactId>
        <version>1.2.15</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-context</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-expression</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-jms</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-aop</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>aopalliance</groupId>
        <artifactId>aopalliance</artifactId>
        <version>1.0</version>
    </dependency>
    <dependency>
        <groupId>cglib</groupId>
        <artifactId>cglib-nodep</artifactId>
        <version>2.2</version>
    </dependency>
    <dependency>
        <groupId>org.aspectj</groupId>
        <artifactId>aspectjweaver</artifactId>
        <version>1.6.8.RELEASE</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-aspects</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-instrument</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-instrument-tomcat</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>javax.persistence</groupId>
        <artifactId>persistence-api</artifactId>
        <version>1.0</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-orm</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-jdbc</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-tx</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-context-support</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>com.opensymphony.quartz</groupId>
        <artifactId>com.springsource.org.quartz</artifactId>
        <version>1.6.2</version>
    </dependency>
    <dependency>
        <groupId>org.beanshell</groupId>
        <artifactId>bsh</artifactId>
        <version>2.0b4</version>
    </dependency>
    <dependency>
        <groupId>org.codehaus.groovy</groupId>
        <artifactId>groovy-all</artifactId>
        <version>1.6.5</version>
    </dependency>
    <dependency>
        <groupId>org.jruby</groupId>
        <artifactId>jruby</artifactId>
        <version>1.4.0</version>
    </dependency>
    <dependency>
        <groupId>com.bea.commonj</groupId>
        <artifactId>com.springsource.commonj</artifactId>
        <version>1.1.0</version>
    </dependency>
    <dependency>
        <groupId>com.jamonapi</groupId>
        <artifactId>jamon</artifactId>
        <version>2.7</version>
    </dependency>
    <dependency>
        <groupId>javax.management</groupId>
        <artifactId>jmxremote</artifactId>
        <version>1.0.1_04</version>
    </dependency>
    <dependency>
        <groupId>javax.management</groupId>
        <artifactId>jmxremote_optional</artifactId>
        <version>1.0.1_04</version>
    </dependency>
    <dependency>
        <groupId>javax.management</groupId>
        <artifactId>jmxri</artifactId>
        <version>1.2.1</version>
    </dependency>
    <dependency>
        <groupId>backport-util-concurrent</groupId>
        <artifactId>backport-util-concurrent</artifactId>
        <version>3.0</version>
    </dependency>
    <dependency>
        <groupId>com.caucho</groupId>
        <artifactId>com.springsource.com.caucho</artifactId>
        <version>3.2.1</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-web</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>commons-fileupload</groupId>
        <artifactId>commons-fileupload</artifactId>
        <version>1.2</version>
    </dependency>
    <dependency>
        <groupId>commons-httpclient</groupId>
        <artifactId>commons-httpclient</artifactId>
        <version>3.1</version>
    </dependency>
    <dependency>
        <groupId>org.codehaus.jackson</groupId>
        <artifactId>com.springsource.org.codehaus.jackson.mapper</artifactId>
        <version>1.0.0</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-oxm</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-webmvc</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-webmvc-portlet</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-struts</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
  </dependencies>
  <build>
    <sourceDirectory>${basedir}/src</sourceDirectory>
    <outputDirectory>${basedir}/WebRoot/WEB-INF/classes</outputDirectory>
    <resources>
      <resource>
        <directory>${basedir}/src</directory>
        <excludes>
          <exclude>**/*.java</exclude>
        </excludes>
      </resource>
    </resources>
    <plugins>
      <plugin>
        <artifactId>maven-war-plugin</artifactId>
        <configuration>
          <webappDirectory>${basedir}/WebRoot</webappDirectory>
          <warSourceDirectory>${basedir}/WebRoot</warSourceDirectory>
        </configuration>
      </plugin>
      <plugin>
        <artifactId>maven-compiler-plugin</artifactId>
        <configuration>
          <source>1.5</source>
          <target>1.5</target>
        </configuration>
      </plugin>
    </plugins>
  </build>
</project>

Spring MVC - Abstract Controller

AbstractCon.java
------------------------------------------------------------------------------------------------------------
package com.anil;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.springframework.web.servlet.ModelAndView;
import org.springframework.web.servlet.mvc.AbstractController;

public class AbstractCon extends AbstractController {
    String str;

    public void setStr(String str) {
        this.str = str;
    }

    @Override
    protected ModelAndView handleRequestInternal(HttpServletRequest req,
            HttpServletResponse res) throws Exception {
        System.out.println("$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$");
        System.out
                .println(" AbstractController : handleRequestInternal : called");
        System.out.println("$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$");
        return new ModelAndView("viewPage", "modelName",
                "test Abstract Controller "+str);
    }

}
-------------------------------------------------------------------------------------------------
web.xml
-------------------------------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8"?>
<web-app version="2.5" xmlns="http://java.sun.com/xml/ns/javaee"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
    http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">

    <servlet>
        <servlet-name>anil</servlet-name>
        <servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
        <load-on-startup>1</load-on-startup>
    </servlet>
    <servlet-mapping>

        <servlet-name>anil</servlet-name>
        <url-pattern>*.htm</url-pattern>
    </servlet-mapping>

    <welcome-file-list>
        <welcome-file>index.jsp</welcome-file>
    </welcome-file-list>
</web-app>
--------------------------------------------------------------------------------------------------------------
anil-servlet.xml
--------------------------------------------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:p="http://www.springframework.org/schema/p"
    xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd">
    <bean id="viewResolver"
        class="org.springframework.web.servlet.view.InternalResourceViewResolver">
        <property name="prefix">
            <value>/WEB-INF/jsp/</value>
        </property>
        <property name="suffix">
            <value>.jsp</value>
        </property>
    </bean>
   
    <bean name="/welcome.htm" class="com.anil.AbstractCon">
    <property name="str" value="AnilKumar"></property>
    </bean>

</beans>
-------------------------------------------------------------------------------------------------------------
index.jsp
-------------------------------------------------------------------------------------------------------------
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<% response.sendRedirect("welcome.htm"); %>
-------------------------------------------------------------------------------------------------------------
viewPage.jsp
-------------------------------------------------------------------------------------------------------------
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>AbstractController</title>
</head>
<body>
${modelName}
</body>
</html>
--------------------------------------------------------------------------------------------------------------
pom.xml
---------------------------------------------------------------------------------------------------------------
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
  <modelVersion>4.0.0</modelVersion>
  <groupId>SpringAbstractControlleer</groupId>
  <artifactId>SpringAbstractControlleer</artifactId>
  <version>0.0.1-SNAPSHOT</version>
  <packaging>war</packaging>
  <name/>
  <description/>
  <dependencies>
    <dependency>
      <groupId>org.apache.openejb</groupId>
      <artifactId>javaee-api</artifactId>
      <version>5.0-1</version>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>javax.faces</groupId>
      <artifactId>jsf-api</artifactId>
      <version>1.2_04</version>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>javax.servlet</groupId>
      <artifactId>jstl</artifactId>
      <version>1.2</version>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>javax.servlet.jsp</groupId>
      <artifactId>jsp-api</artifactId>
      <version>2.1</version>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>javax.faces</groupId>
      <artifactId>jsf-impl</artifactId>
      <version>1.2_04</version>
      <scope>provided</scope>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-core</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-beans</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-asm</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>commons-logging</groupId>
        <artifactId>commons-logging</artifactId>
        <version>1.1.1</version>
    </dependency>
    <dependency>
        <groupId>log4j</groupId>
        <artifactId>log4j</artifactId>
        <version>1.2.15</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-context</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-expression</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-jms</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-aop</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>aopalliance</groupId>
        <artifactId>aopalliance</artifactId>
        <version>1.0</version>
    </dependency>
    <dependency>
        <groupId>cglib</groupId>
        <artifactId>cglib-nodep</artifactId>
        <version>2.2</version>
    </dependency>
    <dependency>
        <groupId>org.aspectj</groupId>
        <artifactId>aspectjweaver</artifactId>
        <version>1.6.8.RELEASE</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-aspects</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-instrument</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-instrument-tomcat</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>javax.persistence</groupId>
        <artifactId>persistence-api</artifactId>
        <version>1.0</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-orm</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-jdbc</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-tx</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-context-support</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>com.opensymphony.quartz</groupId>
        <artifactId>com.springsource.org.quartz</artifactId>
        <version>1.6.2</version>
    </dependency>
    <dependency>
        <groupId>org.beanshell</groupId>
        <artifactId>bsh</artifactId>
        <version>2.0b4</version>
    </dependency>
    <dependency>
        <groupId>org.codehaus.groovy</groupId>
        <artifactId>groovy-all</artifactId>
        <version>1.6.5</version>
    </dependency>
    <dependency>
        <groupId>org.jruby</groupId>
        <artifactId>jruby</artifactId>
        <version>1.4.0</version>
    </dependency>
    <dependency>
        <groupId>com.bea.commonj</groupId>
        <artifactId>com.springsource.commonj</artifactId>
        <version>1.1.0</version>
    </dependency>
    <dependency>
        <groupId>com.jamonapi</groupId>
        <artifactId>jamon</artifactId>
        <version>2.7</version>
    </dependency>
    <dependency>
        <groupId>javax.management</groupId>
        <artifactId>jmxremote</artifactId>
        <version>1.0.1_04</version>
    </dependency>
    <dependency>
        <groupId>javax.management</groupId>
        <artifactId>jmxremote_optional</artifactId>
        <version>1.0.1_04</version>
    </dependency>
    <dependency>
        <groupId>javax.management</groupId>
        <artifactId>jmxri</artifactId>
        <version>1.2.1</version>
    </dependency>
    <dependency>
        <groupId>backport-util-concurrent</groupId>
        <artifactId>backport-util-concurrent</artifactId>
        <version>3.0</version>
    </dependency>
    <dependency>
        <groupId>com.caucho</groupId>
        <artifactId>com.springsource.com.caucho</artifactId>
        <version>3.2.1</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-web</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>commons-fileupload</groupId>
        <artifactId>commons-fileupload</artifactId>
        <version>1.2</version>
    </dependency>
    <dependency>
        <groupId>commons-httpclient</groupId>
        <artifactId>commons-httpclient</artifactId>
        <version>3.1</version>
    </dependency>
    <dependency>
        <groupId>org.codehaus.jackson</groupId>
        <artifactId>com.springsource.org.codehaus.jackson.mapper</artifactId>
        <version>1.0.0</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-oxm</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-webmvc</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-webmvc-portlet</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-struts</artifactId>
        <version>3.0.1.RELEASE-A</version>
    </dependency>
  </dependencies>
  <build>
    <sourceDirectory>${basedir}/src</sourceDirectory>
    <outputDirectory>${basedir}/WebRoot/WEB-INF/classes</outputDirectory>
    <resources>
      <resource>
        <directory>${basedir}/src</directory>
        <excludes>
          <exclude>**/*.java</exclude>
        </excludes>
      </resource>
    </resources>
    <plugins>
      <plugin>
        <artifactId>maven-war-plugin</artifactId>
        <configuration>
          <webappDirectory>${basedir}/WebRoot</webappDirectory>
          <warSourceDirectory>${basedir}/WebRoot</warSourceDirectory>
        </configuration>
      </plugin>
      <plugin>
        <artifactId>maven-compiler-plugin</artifactId>
        <configuration>
          <source>1.5</source>
          <target>1.5</target>
        </configuration>
      </plugin>
    </plugins>
  </build>
</project>