KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > objectweb > jac > samples > photos > Run


1 /*
2   Copyright (C) AOPSYS (http://www.aopsys.com)
3
4   This program is free software; you can redistribute it and/or modify
5   it under the terms of the GNU General Public License as published by
6   the Free Software Foundation; either version 2 of the License, or
7   (at your option) any later version.
8
9   This program is distributed in the hope that it will be useful,
10   but WITHOUT ANY WARRANTY; without even the implied warranty of
11   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12   GNU General Public License for more details.
13
14   You should have received a copy of the GNU General Public License
15   along with this program; if not, write to the Free Software
16   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */

17
18 package org.objectweb.jac.samples.photos;
19
20 import org.objectweb.jac.aspects.gui.DisplayContext;
21 import org.objectweb.jac.aspects.gui.Actions;
22
23 public class Run {
24
25     /**
26      * This sample is a photo album, used to stock and visualize photos.
27      */

28     public static void main(String JavaDoc[] args)
29     {
30         photos = new PhotoRepository();
31         users = new Users();
32     }
33
34     static PhotoRepository photos;
35     static Users users;
36
37     // Gui methods
38

39     /**
40      * View list of photos
41      */

42     public static void viewPhotos(DisplayContext context, String JavaDoc panelID) {
43         Actions.viewObject(context,"photorepository#0",panelID);
44     }
45
46     /**
47      * View list of Users
48      */

49     public static void viewUsers(DisplayContext context, String JavaDoc panelID) {
50         Actions.viewObject(context,"users#0",panelID);
51     }
52 }
53
Popular Tags