Examples of SourceException


Examples of org.apache.excalibur.source.SourceException

                try {
                    nat.rollback();
                } catch (Exception rbe) {
                    getLogger().error("Rollback failed for moving source", rbe);
                }
                throw new SourceException("Could not move source.", se);
            }
        } else {
            org.apache.excalibur.source.SourceUtil.move(this, source);
        }
    }
View Full Code Here

Examples of org.apache.excalibur.source.SourceException

                try {
                    nat.rollback();
                } catch (Exception rbe) {
                    getLogger().error("Rollback failed for moving source", rbe);
                }
                throw new SourceException("Could not move source.", se);
            }
        } else {
            org.apache.excalibur.source.SourceUtil.copy(this, source);
        }
    }
View Full Code Here

Examples of org.apache.excalibur.source.SourceException

                if (((String) children.nextElement()).startsWith(this.config.getFilesPath())) {
                    i++;
                }
            return i;
        } catch (SlideException se) {
            throw new SourceException("Could not get children", se);
        }
    }
View Full Code Here

Examples of org.apache.excalibur.source.SourceException

                    i++;
                }
            }
            return null;
        } catch (SlideException se) {
            throw new SourceException("Could not get children", se);
        }
    }
View Full Code Here

Examples of org.apache.excalibur.source.SourceException

            try {
                nat.rollback();
            } catch (Exception rbe) {
                getLogger().error("Rollback failed for creating collection", rbe);
            }
            throw new SourceException("Could not create collection.", se);
        }
    }
View Full Code Here

Examples of org.apache.excalibur.source.SourceException

            try {
                ObjectNode objectnode = structure.retrieve(this.slideToken,
                                                           subject);

                if ( !(objectnode instanceof SubjectNode)) {
                    throw new SourceException("Principal '"+
                                              ((PrincipalSourcePermission) sourcepermission).getPrincipal()+
                                              "' doesn't exists");
                }
            } catch (SlideException se) {
                throw new SourceException("Could not retrieve object for principal '"+
                                          ((PrincipalSourcePermission) sourcepermission).getPrincipal()+
                                          "'", se);
            }

        } else if (sourcepermission instanceof GroupSourcePermission) {
            subject = config.getUsersPath()+"/"+
                      ((GroupSourcePermission) sourcepermission).getGroup();

            // Test if group exists
            try {
                ObjectNode objectnode = structure.retrieve(this.slideToken,
                                                           subject);

                if ( !(objectnode instanceof GroupNode)) {
                    throw new SourceException("Group '"+
                                              ((GroupSourcePermission) sourcepermission).getGroup()+
                                              "' doesn't exists");
                }
            } catch (SlideException se) {
                throw new SourceException("Could not retrieve object for group '"+
                                          ((GroupSourcePermission) sourcepermission).getGroup()+
                                          "'", se);
            }

            subject = "+"+subject; // Additional '+' to expand the group
        } else {
            throw new SourceException("Does't support category of permission");
        }

        boolean negative = sourcepermission.isNegative();
        boolean inheritable = sourcepermission.isInheritable();
View Full Code Here

Examples of org.apache.excalibur.source.SourceException

            try {
                nat.rollback();
            } catch (Exception rbe) {
                getLogger().error("Rollback failed for granting permission", rbe);
            }  
            throw new SourceException("Couldn't grant permission", se);
        }
    }
View Full Code Here

Examples of org.apache.excalibur.source.SourceException

            try {
                ObjectNode objectnode = structure.retrieve(this.slideToken,
                                                           subject);

                if ( !(objectnode instanceof SubjectNode)) {
                    throw new SourceException("Principal '"+
                                              ((PrincipalSourcePermission) sourcepermission).getPrincipal()+
                                              "' doesn't exists");
                }
            } catch (SlideException se) {
                throw new SourceException("Could not retrieve object for principal '"+
                                          ((PrincipalSourcePermission) sourcepermission).getPrincipal()+
                                          "'", se);
            }

        } else if (sourcepermission instanceof GroupSourcePermission) {
            subject = config.getUsersPath()+"/"+
                      ((GroupSourcePermission) sourcepermission).getGroup();

            // Test if group exists
            try {
                ObjectNode objectnode = structure.retrieve(this.slideToken,
                                                           subject);

                if ( !(objectnode instanceof GroupNode)) {
                    throw new SourceException("Group '"+
                                              ((GroupSourcePermission) sourcepermission).getGroup()+
                                              "' doesn't exists");
                }
            } catch (SlideException se) {
                throw new SourceException("Could not retrieve object for group '"+
                                          ((GroupSourcePermission) sourcepermission).getGroup()+
                                          "'", se);
            }

            subject = "+"+subject; // Additional '+' to expand the group
        } else {
            throw new SourceException("Does't support category of permission");
        }

        boolean negative = sourcepermission.isNegative();
        boolean inheritable = sourcepermission.isInheritable();
View Full Code Here

Examples of org.apache.excalibur.source.SourceException

            try {
                nat.rollback();
            } catch (Exception rbe) {
                getLogger().error("Rollback failed for removing permission", rbe);
            }
            throw new SourceException("Couldn't remove permission", se);
        }
    }
View Full Code Here

Examples of org.apache.excalibur.source.SourceException

                        }

                        sourcepermissions.add(sourcepermission);
                    }
                } catch (SlideException se) {
                    throw new SourceException("Exception eccurs while retrieveing source permission",
                                              se);
                }

                inheritedPermissions = true;

                try {
                    current = structure.getParent(this.slideToken, current);
                } catch (SlideException e) {
                    break;
                }
            }

            SourcePermission[] sourcepermissionArray = new SourcePermission[sourcepermissions.size()];

            return (SourcePermission[]) sourcepermissions.toArray((Object[]) sourcepermissionArray);

        } catch (SlideException se) {
            throw new SourceException("Exception eccurs while retrieveing source permission",
                                      se);
        }
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.