Source Code Cross Referenced for Lock.java in  » Source-Control » tmatesoft-SVN » org » tigris » subversion » javahl » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Source Control » tmatesoft SVN » org.tigris.subversion.javahl 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        /**
002:         * @copyright
003:         * ====================================================================
004:         * Copyright (c) 2003-2005 CollabNet.  All rights reserved.
005:         *
006:         * This software is licensed as described in the file COPYING, which
007:         * you should have received as part of this distribution.  The terms
008:         * are also available at http://subversion.tigris.org/license-1.html.
009:         * If newer versions of this license are posted there, you may use a
010:         * newer version instead, at your option.
011:         *
012:         * This software consists of voluntary contributions made by many
013:         * individuals.  For exact contribution history, see the revision
014:         * history and logs, available at http://subversion.tigris.org/.
015:         * ====================================================================
016:         * 
017:         * @endcopyright
018:         */package org.tigris.subversion.javahl;
019:
020:        import java.util.Date;
021:
022:        /**
023:         * class to describe a lock. It is return by the lock operation
024:         * @since 1.2
025:         */
026:        public class Lock {
027:            /**
028:             * the owner of the lock
029:             */
030:            private String owner;
031:            /**
032:             * the path of the locked item
033:             */
034:            private String path;
035:            /**
036:             * the token provided during the lock operation
037:             */
038:            private String token;
039:            /**
040:             * the comment provided during the lock operation
041:             */
042:            private String comment;
043:            /**
044:             * the date when the lock was created
045:             */
046:            private long creationDate;
047:            /**
048:             * the date when the lock will expire
049:             */
050:            private long expirationDate;
051:
052:            /**
053:             * this constructor should only called from JNI code
054:             * @param owner             the owner of the lock
055:             * @param path              the path of the locked item
056:             * @param token             the lock token
057:             * @param comment           the lock comment
058:             * @param creationDate      the date when the lock was created
059:             * @param expirationDate    the date when the lock will expire
060:             */
061:            Lock(String owner, String path, String token, String comment,
062:                    long creationDate, long expirationDate) {
063:                this .owner = owner;
064:                this .path = path;
065:                this .token = token;
066:                this .comment = comment;
067:                this .creationDate = creationDate;
068:                this .expirationDate = expirationDate;
069:            }
070:
071:            /**
072:             * @return the owner of the lock
073:             */
074:            public String getOwner() {
075:                return owner;
076:            }
077:
078:            /**
079:             * @return the path of the locked item
080:             */
081:            public String getPath() {
082:                return path;
083:            }
084:
085:            /**
086:             * @return the token provided during the lock operation
087:             */
088:            public String getToken() {
089:                return token;
090:            }
091:
092:            /**
093:             * @return the comment provided during the lock operation
094:             */
095:            public String getComment() {
096:                return comment;
097:            }
098:
099:            /**
100:             * @return the date the lock was created
101:             */
102:            public Date getCreationDate() {
103:                if (creationDate == 0)
104:                    return null;
105:                else
106:                    return new Date(creationDate / 1000);
107:            }
108:
109:            /**
110:             * @return the date when the lock will expire
111:             */
112:            public Date getExpirationDate() {
113:                if (expirationDate == 0)
114:                    return null;
115:                else
116:                    return new Date(expirationDate / 1000);
117:            }
118:
119:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.