001    /**
002     * Copyright (c) 2000-2010 Liferay, Inc. All rights reserved.
003     *
004     * The contents of this file are subject to the terms of the Liferay Enterprise
005     * Subscription License ("License"). You may not use this file except in
006     * compliance with the License. You can obtain a copy of the License by
007     * contacting Liferay, Inc. See the License for the specific language governing
008     * permissions and limitations under the License, including but not limited to
009     * distribution rights of the Software.
010     *
011     *
012     *
013     */
014    
015    package com.liferay.portal.kernel.dao.orm;
016    
017    /**
018     * @author Brian Wing Shun Chan
019     */
020    public interface LockMode {
021    
022            public static final LockMode FORCE = new LockModeImpl("FORCE");
023    
024            public static final LockMode NONE = new LockModeImpl("NONE");
025    
026            public static final LockMode OPTIMISTIC = new LockModeImpl("OPTIMISTIC");
027    
028            public static final LockMode OPTIMISTIC_FORCE_INCREMENT = new LockModeImpl(
029                    "OPTIMISTIC_FORCE_INCREMENT");
030    
031            public static final LockMode PESSIMISTIC_FORCE_INCREMENT = new LockModeImpl(
032                    "PESSIMISTIC_FORCE_INCREMENT");
033    
034            public static final LockMode PESSIMISTIC_READ = new LockModeImpl(
035                    "PESSIMISTIC_READ");
036    
037            public static final LockMode PESSIMISTIC_WRITE = new LockModeImpl(
038                    "PESSIMISTIC_WRITE");
039    
040            public static final LockMode READ = new LockModeImpl("READ");
041    
042            public static final LockMode UPGRADE = new LockModeImpl("UPGRADE");
043    
044            public static final LockMode UPGRADE_NOWAIT =
045                    new LockModeImpl("UPGRADE_NOWAIT");
046    
047            public static final LockMode WRITE = new LockModeImpl("WRITE");
048    
049            public String getName();
050    
051    }