KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > apache > webdav > lib > Subscription


1 // vi: set ts=3 sw=3:
2
package org.apache.webdav.lib;
3
4 /**
5  * Object that holds information about a single WebDAV subscription.
6  *
7  * @see org.apache.webdav.lib.WebdavResource#subscribeMethod(String, String, String, long, int, long)
8  */

9 public class Subscription
10 {
11    public static final String JavaDoc UPDATE_NOTIFICATION = "update";
12    public static final String JavaDoc NEW_MEMBER_NOTIFICATION = "update/newmember";
13    public static final String JavaDoc DELETE_NOTIFICATION = "delete";
14    public static final String JavaDoc MOVE_NOTIFICATION = "move";
15    
16    private int id;
17    private long lifetime;
18    private String JavaDoc callback;
19    private String JavaDoc contentLocation;
20    private String JavaDoc notificationType;
21    private String JavaDoc path;
22    
23    public Subscription(String JavaDoc path, int id, String JavaDoc callback, long lifetime,
24          String JavaDoc contentLocation, String JavaDoc notificationType)
25    {
26       this.path = path;
27       this.id = id;
28       this.callback = callback;
29       this.lifetime = lifetime;
30       this.contentLocation = contentLocation;
31       this.notificationType = notificationType;
32    }
33    
34    public String JavaDoc getCallback()
35    {
36       return callback;
37    }
38    public String JavaDoc getContentLocation()
39    {
40       return contentLocation;
41    }
42    public int getId()
43    {
44       return id;
45    }
46    public long getLifetime()
47    {
48       return lifetime;
49    }
50    public String JavaDoc getNotificationType()
51    {
52       return notificationType;
53    }
54    public String JavaDoc getPath()
55    {
56       return path;
57    }
58 }
59
Popular Tags