1 ///////////////////////////////////////////////////////////////////////////// 2 // Copyright (c) 2009-2014 Alan Wright. All rights reserved. 3 // Distributable under the terms of either the Apache License (Version 2.0) 4 // or the GNU Lesser General Public License. 5 ///////////////////////////////////////////////////////////////////////////// 6 7 #include "LuceneInc.h" 8 #include "FSLockFactory.h" 9 10 namespace Lucene { 11 FSLockFactory()12FSLockFactory::FSLockFactory() { 13 } 14 ~FSLockFactory()15FSLockFactory::~FSLockFactory() { 16 } 17 setLockDir(const String & lockDir)18void FSLockFactory::setLockDir(const String& lockDir) { 19 if (!this->lockDir.empty()) { 20 boost::throw_exception(IllegalStateException(L"You can set the lock directory for this factory only once.")); 21 } 22 this->lockDir = lockDir; 23 } 24 getLockDir()25String FSLockFactory::getLockDir() { 26 return lockDir; 27 } 28 29 } 30