Update of /cvsroot/pfc/pfc-demo/src/java/portal/demo/velocity
In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv15113/src/java/portal/demo/velocity
Modified Files:
SimpleLayoutDemoInfo.java VelocityDemoPanel.java
LayoutDemoPanel.java SimpleLayoutDemo.java
Log Message:
Refactored to support generics.
Added a default serialization id for all serializable classes.
Index: SimpleLayoutDemoInfo.java
===================================================================
RCS file: /cvsroot/pfc/pfc-demo/src/java/portal/demo/velocity/SimpleLayoutDemoInfo.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** SimpleLayoutDemoInfo.java 26 Jan 2005 20:15:06 -0000 1.2
--- SimpleLayoutDemoInfo.java 7 Aug 2010 21:30:35 -0000 1.3
***************
*** 6,9 ****
--- 6,11 ----
public class SimpleLayoutDemoInfo implements DemoEntryInfo
{
+ private static final long serialVersionUID = 1L;
+
public String getShortName()
{
Index: SimpleLayoutDemo.java
===================================================================
RCS file: /cvsroot/pfc/pfc-demo/src/java/portal/demo/velocity/SimpleLayoutDemo.java,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** SimpleLayoutDemo.java 13 Sep 2005 11:35:27 -0000 1.3
--- SimpleLayoutDemo.java 7 Aug 2010 21:30:35 -0000 1.4
***************
*** 8,11 ****
--- 8,13 ----
public class SimpleLayoutDemo extends Panel implements DemoEntry
{
+ private static final long serialVersionUID = 1L;
+
public SimpleLayoutDemo()
{
***************
*** 27,31 ****
}
! public Component getComponent()
{
return this;
--- 29,33 ----
}
! public Component<?> getComponent()
{
return this;
Index: LayoutDemoPanel.java
===================================================================
RCS file: /cvsroot/pfc/pfc-demo/src/java/portal/demo/velocity/LayoutDemoPanel.java,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -d -r1.6 -r1.7
*** LayoutDemoPanel.java 13 Sep 2005 11:35:27 -0000 1.6
--- LayoutDemoPanel.java 7 Aug 2010 21:30:35 -0000 1.7
***************
*** 13,16 ****
--- 13,18 ----
public class LayoutDemoPanel extends Panel
{
+ private static final long serialVersionUID = 1L;
+
public LayoutDemoPanel()
{
***************
*** 28,35 ****
_greetingLabel = new Label();
! _greetingLabel.getLabelModel().setString("Hello");
label = new Label();
! label.getLabelModel().setString("Your name:");
_textInput = new TextInput();
--- 30,37 ----
_greetingLabel = new Label();
! _greetingLabel.getLabelModel().setValue("Hello");
label = new Label();
! label.getLabelModel().setValue("Your name:");
_textInput = new TextInput();
***************
*** 59,66 ****
private class MyAction implements IAction
{
public void doAction()
{
! _greetingLabel.getLabelModel().setString(
! "Hello " + _textInput.getStringModel().getString());
}
}
--- 61,70 ----
private class MyAction implements IAction
{
+ private static final long serialVersionUID = 1L;
+
public void doAction()
{
! _greetingLabel.getLabelModel().setValue(
! "Hello " + _textInput.getStringModel().getValue());
}
}
Index: VelocityDemoPanel.java
===================================================================
RCS file: /cvsroot/pfc/pfc-demo/src/java/portal/demo/velocity/VelocityDemoPanel.java,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -d -r1.6 -r1.7
*** VelocityDemoPanel.java 13 Sep 2005 11:35:27 -0000 1.6
--- VelocityDemoPanel.java 7 Aug 2010 21:30:35 -0000 1.7
***************
*** 10,13 ****
--- 10,15 ----
public class VelocityDemoPanel extends Panel
{
+ private static final long serialVersionUID = 1L;
+
public VelocityDemoPanel()
{
***************
*** 21,25 ****
_label = new Label();
! _label.getLabelModel().setString("Hello");
_textInput = new TextInput();
--- 23,27 ----
_label = new Label();
! _label.getLabelModel().setValue("Hello");
_textInput = new TextInput();
***************
*** 40,47 ****
private class MyAction implements IAction
{
public void doAction()
{
! _label.getLabelModel().setString(
! "Hello " + _textInput.getStringModel().getString());
}
}
--- 42,51 ----
private class MyAction implements IAction
{
+ private static final long serialVersionUID = 1L;
+
public void doAction()
{
! _label.getLabelModel().setValue(
! "Hello " + _textInput.getStringModel().getValue());
}
}
|