Package org.apache.lucene.gdata.storage

Examples of org.apache.lucene.gdata.storage.ResourceNotFoundException


        if (set.size() > 1)
            throw new StorageException("Query for feed id " + feedId
                    + " returns more than one result");
        if (set.hasNext())
        return (BaseFeed<BaseFeed, BaseEntry>) set.next();
        throw new ResourceNotFoundException("can not find feed for given feed id -- "
                + feedId);

    }
View Full Code Here


        if (resultSet.size() > 1)
            throw new StorageException(
                    "Entry query returned not a unique result");
        if (resultSet.hasNext())
            return resultSet.next();
        throw new ResourceNotFoundException("no entry with entryID: " + id
                + " stored -- query returned no result");
    }
View Full Code Here

        if (set.size() > 1)
            throw new StorageException(
                    "Account query returned not a unique result -- account name: "
                            + accountName);
        if (!set.hasNext())
            throw new ResourceNotFoundException(
                    "No such account stored -- query returned not result for account name: "
                            + accountName);

        return (GDataAccount) set.next();
    }
View Full Code Here

                modifier.deleteEntry(new StorageEntryWrapper(entry,StorageOperation.DELETE));
            }else
                throw new ModificationConflictException("The entry version does not match -- entry "+entry.getId()+" feed:"+entry.getFeedId()+" version: "+entry.getVersion());
        }
        else
            throw new ResourceNotFoundException("Entry for entry id: "+entry.getId()+" is not stored");
        }catch (IOException e) {
            throw new StorageException("Can not access storage");
        }finally{
            if(query != null)
                query.decrementRef();
View Full Code Here

                    modifier.updateEntry(wrapper);
                }else
                    throw new ModificationConflictException("The entry version does not match -- entry "+entry.getId()+" feed:"+entry.getFeedId()+" version: "+entry.getVersion());
             
            }else
                throw new ResourceNotFoundException("Entry for entry id: "+entry.getId()+" is not stored");
           
        } catch (IOException e) {
            LOG.error("Can't update entry for feedID: " + entry.getFeedId()
                    + "; entryId: " + entry.getId() + " -- " + e.getMessage(),
                    e);
View Full Code Here

        try {
            query = this.controller.getStorageQuery();
            BaseEntry retVal = query.get().singleEntryQuery(entry.getId(),
                    entry.getFeedId(), entry.getServiceConfig());
            if(retVal == null)
                throw new ResourceNotFoundException("can not get entry for entry ID "+entry.getId());
            return retVal;
        } catch (Exception e) {
            LOG.error("Can't get entry for feedID: " + entry.getFeedId()
                    + "; entryId: " + entry.getId() + " -- " + e.getMessage(),
                    e);
View Full Code Here

TOP

Related Classes of org.apache.lucene.gdata.storage.ResourceNotFoundException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.