[Treebase-guts] SF.net SVN: treebase:[248]
trunk/treebase-web/src/main/java/org/cipres/ treebase/web
From: <rv...@us...> - 2009-11-04 16:54:16
|
Revision: 248 http://treebase.svn.sourceforge.net/treebase/?rev=248&view=rev Author: rvos Date: 2009-11-04 16:54:08 +0000 (Wed, 04 Nov 2009) Log Message: ----------- Removed outdated CIPRES/SDSC disclaimers Modified Paths: -------------- trunk/treebase-web/src/main/java/org/cipres/treebase/web/Constants.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AbstractUserController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AddAuthorController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AddPersonController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AdminAndUserGenericController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AdminDeletingUserStepOneController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AdminDeletingUserStepTwoController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AdminMergingPersonsController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AdminMergingUsersController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AdminOverridingUserFormController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AdminSelectPersonsController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AdminSelectUsersController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AdminUpdatingUserInfoController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AjaxMultipartResolver.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AjaxProgressListener.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AnalysisFormController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AnalysisStepFormController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AnalyzedDataFormController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AnyObjectAsRDFController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AppletInteractionController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AuthorFormController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/BaseFormController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ChangeStudyStatusController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/CitationFormController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/DeleteAMatrixController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/DeleteARowSegmentController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/DeleteATreeBlockController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/DeleteATreeController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/DeleteStudyController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/DirectMapToPhyloWidgetController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/DirectToPhyloWidgetController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/DisplayAnalysisController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/DisplaySubmissionController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/DisplaySubmissionMenuController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/DownloadAMatrixController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/DownloadANexusFileController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/DownloadANexusRCTFileController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/DownloadAStudyController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/DownloadATreeBlockController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/DownloadATreeController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/DownloadAnAnalysisStepController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/EditSetTaxonLabelController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/EditTaxonLabelController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/EditorFormController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ExportRowSegmentDataController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ExportRowSegmentTemplateController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/HelpController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ListAnalysisController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ListAnalysisStepController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ListAnalyzedDataController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ListMatrixController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ListMatrixRowController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ListMatrixRowSegmentController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ListSearchStudyController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ListSubmissionController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ListTaxaController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ListTaxaSearchController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ListTreeBlockController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ListTreeController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/MatrixRowSegmentFormController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/MatrixSearchController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/NexusFilesController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/PasswordFormController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/PeopleFormController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/PeopleFormSearchController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ProcessUserController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ReadOnlyListTreeController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ReadyStateController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ReadyStateStudiesController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/RegisterUserController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/RowSegmentDataTableController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/SearchBySubmissionIDController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/SearchController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/SearchFormController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/SearchResultsAsRDFController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/SearchStudyController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/SearchSummaryController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/SelectStudiesController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ShortPathUrlFilenameViewController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/SingleRowSegmentController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/StudyFormController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/StudySearchController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/SubmissionToJsonController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/SummaryController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/TestParserController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/TreeParserController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/TreeParserResultController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/TreeSearchController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/TreeTopSearchController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/UpdateAnalyzedDataListController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/UpdateStudyQueryController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/UploadFileController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/UploadFileSummaryController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/UploadRowSegmentDataController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/UserFormController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/UserManagementController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ViewAllRowSegmentDataController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/exceptions/DeprecatedFeatureError.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/exceptions/EmptyStudyException.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/exceptions/EmptySubmissionException.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/listeners/EventListener.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/listeners/StartupListener.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/model/AGenericList.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/model/AnalysisCommand.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/model/AnalysisStepCommand.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/model/AnalyzedDataCommand.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/model/CitationCommand.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/model/EditFieldCommand.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/model/FileBean.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/model/HelpControllerAction.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/model/LabelValue.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/model/MatrixRowCommand.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/model/MatrixTreeData.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/model/MultiFileBean.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/model/MyProgressionListener.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/model/RowSegmentCommand.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/model/SearchCommand.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/model/SearchCriteriaCommand.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/model/StudyCommand.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/model/TaxonSearchCommand.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/model/User.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/ControllerUtil.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/SearchMessageSetter.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/StringUtil.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/WebUtil.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/validators/UserFormValidator.java Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/Constants.java =================================================================== --- trunk/treebase-web/src/main/java/org/cipres/treebase/web/Constants.java 2009-11-04 16:51:46 UTC (rev 247) +++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/Constants.java 2009-11-04 16:54:08 UTC (rev 248) @@ -1,22 +1,3 @@ -/* - * Copyright 2006 CIPRES project. http://www.phylo.org/ All Rights Reserved. - * - * Permission to use, copy, modify, and distribute this software and its documentation for - * educational, research and non-profit purposes, without fee, and without a written agreement is - * hereby granted, provided that the above copyright notice, this paragraph and the following two - * paragraphs appear in all copies. - * - * Permission to incorporate this software into commercial products may be obtained by contacting - * us: http://www.phylo.org/contactUs.html - * - * The software program and documentation are supplied "as is". In no event shall the CIPRES project - * be liable to any party for direct, indirect, special, incidental, or consequential damages, - * including lost profits, arising out of the use of this software and its documentation, even if - * the CIPRES project has been advised of the possibility of such damage. The CIPRES project - * specifically disclaims any warranties, including, but not limited to, the implied warranties of - * merchantability and fitness for a particular purpose. The CIPRES project has no obligations to - * provide maintenance, support, updates, enhancements, or modifications. - */ package org.cipres.treebase.web; Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AbstractUserController.java =================================================================== --- trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AbstractUserController.java 2009-11-04 16:51:46 UTC (rev 247) +++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AbstractUserController.java 2009-11-04 16:54:08 UTC (rev 248) @@ -1,24 +1,3 @@ -/* - * CIPRES Copyright (c) 2005- 2008, The Regents of the University of California All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are permitted - * provided that the following conditions are met: * Redistributions of source code must retain the - * above copyright notice, this list of conditions and the following disclaimer. * Redistributions - * in binary form must reproduce the above copyright notice, this list of conditions and the - * following disclaimer in the documentation and/or other materials provided with the distribution. * - * Neither the name of the University of California or the San Diego Supercomputer Center nor the - * names of its contributors may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR - * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, - * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, - * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY - * WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ package org.cipres.treebase.web.controllers; import javax.servlet.http.HttpServletRequest; Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AddAuthorController.java =================================================================== --- trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AddAuthorController.java 2009-11-04 16:51:46 UTC (rev 247) +++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AddAuthorController.java 2009-11-04 16:54:08 UTC (rev 248) @@ -1,24 +1,3 @@ -/* - * CIPRES Copyright (c) 2005- 2008, The Regents of the University of California All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are permitted - * provided that the following conditions are met: * Redistributions of source code must retain the - * above copyright notice, this list of conditions and the following disclaimer. * Redistributions - * in binary form must reproduce the above copyright notice, this list of conditions and the - * following disclaimer in the documentation and/or other materials provided with the distribution. * - * Neither the name of the University of California or the San Diego Supercomputer Center nor the - * names of its contributors may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR - * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, - * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, - * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY - * WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ package org.cipres.treebase.web.controllers; import java.util.List; Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AddPersonController.java =================================================================== --- trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AddPersonController.java 2009-11-04 16:51:46 UTC (rev 247) +++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AddPersonController.java 2009-11-04 16:54:08 UTC (rev 248) @@ -1,24 +1,3 @@ -/* - * CIPRES Copyright (c) 2005- 2008, The Regents of the University of California All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are permitted - * provided that the following conditions are met: * Redistributions of source code must retain the - * above copyright notice, this list of conditions and the following disclaimer. * Redistributions - * in binary form must reproduce the above copyright notice, this list of conditions and the - * following disclaimer in the documentation and/or other materials provided with the distribution. * - * Neither the name of the University of California or the San Diego Supercomputer Center nor the - * names of its contributors may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR - * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, - * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, - * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY - * WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ package org.cipres.treebase.web.controllers; import java.util.Collection; Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AdminAndUserGenericController.java =================================================================== --- trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AdminAndUserGenericController.java 2009-11-04 16:51:46 UTC (rev 247) +++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AdminAndUserGenericController.java 2009-11-04 16:54:08 UTC (rev 248) @@ -1,24 +1,3 @@ -/* - * CIPRES Copyright (c) 2005- 2008, The Regents of the University of California All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are permitted - * provided that the following conditions are met: * Redistributions of source code must retain the - * above copyright notice, this list of conditions and the following disclaimer. * Redistributions - * in binary form must reproduce the above copyright notice, this list of conditions and the - * following disclaimer in the documentation and/or other materials provided with the distribution. * - * Neither the name of the University of California or the San Diego Supercomputer Center nor the - * names of its contributors may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR - * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, - * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, - * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY - * WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ package org.cipres.treebase.web.controllers; import javax.servlet.ServletException; Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AdminDeletingUserStepOneController.java =================================================================== --- trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AdminDeletingUserStepOneController.java 2009-11-04 16:51:46 UTC (rev 247) +++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AdminDeletingUserStepOneController.java 2009-11-04 16:54:08 UTC (rev 248) @@ -1,24 +1,3 @@ -/* - * CIPRES Copyright (c) 2005- 2008, The Regents of the University of California All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are permitted - * provided that the following conditions are met: * Redistributions of source code must retain the - * above copyright notice, this list of conditions and the following disclaimer. * Redistributions - * in binary form must reproduce the above copyright notice, this list of conditions and the - * following disclaimer in the documentation and/or other materials provided with the distribution. * - * Neither the name of the University of California or the San Diego Supercomputer Center nor the - * names of its contributors may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR - * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, - * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, - * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY - * WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ package org.cipres.treebase.web.controllers; import javax.servlet.http.HttpServletRequest; Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AdminDeletingUserStepTwoController.java =================================================================== --- trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AdminDeletingUserStepTwoController.java 2009-11-04 16:51:46 UTC (rev 247) +++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AdminDeletingUserStepTwoController.java 2009-11-04 16:54:08 UTC (rev 248) @@ -1,22 +1,3 @@ -/* - * Copyright 2008 CIPRES project. http://www.phylo.org/ All Rights Reserved. - * - * Permission to use, copy, modify, and distribute this software and its documentation for - * educational, research and non-profit purposes, without fee, and without a written agreement is - * hereby granted, provided that the above copyright notice, this paragraph and the following two - * paragraphs appear in all copies. - * - * Permission to incorporate this software into commercial products may be obtained by contacting - * us: http://www.phylo.org/contactUs.html - * - * The software program and documentation are supplied "as is". In no event shall the CIPRES project - * be liable to any party for direct, indirect, special, incidental, or consequential damages, - * including lost profits, arising out of the use of this software and its documentation, even if - * the CIPRES project has been advised of the possibility of such damage. The CIPRES project - * specifically disclaims any warranties, including, but not limited to, the implied warranties of - * merchantability and fitness for a particular purpose. The CIPRES project has no obligations to - * provide maintenance, support, updates, enhancements, or modifications. - */ package org.cipres.treebase.web.controllers; Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AdminMergingPersonsController.java =================================================================== --- trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AdminMergingPersonsController.java 2009-11-04 16:51:46 UTC (rev 247) +++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AdminMergingPersonsController.java 2009-11-04 16:54:08 UTC (rev 248) @@ -1,24 +1,3 @@ -/* - * CIPRES Copyright (c) 2005- 2008, The Regents of the University of California All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are permitted - * provided that the following conditions are met: * Redistributions of source code must retain the - * above copyright notice, this list of conditions and the following disclaimer. * Redistributions - * in binary form must reproduce the above copyright notice, this list of conditions and the - * following disclaimer in the documentation and/or other materials provided with the distribution. * - * Neither the name of the University of California or the San Diego Supercomputer Center nor the - * names of its contributors may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR - * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, - * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, - * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY - * WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - */ package org.cipres.treebase.web.controllers; import java.util.ArrayList; Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AdminMergingUsersController.java =================================================================== --- trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AdminMergingUsersController.java 2009-11-04 16:51:46 UTC (rev 247) +++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/AdminMergingUsersController.java 2009-11-04 16:54:08 UTC (rev 248) @@ -1,24 +1,3 @@ -/* - * CIPRES Copyright (c) 2005- 2008, The Regents of the University of California All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are permitted - * provided that the following conditions are met: * Redistributions of source code must retain the - ... [truncated message content] |
[Treebase-guts] SF.net SVN: treebase:[462]
trunk/treebase-web/src/main/java/org/cipres/ treebase/web
From: <rv...@us...> - 2010-01-15 17:19:56
|
Revision: 462 http://treebase.svn.sourceforge.net/treebase/?rev=462&view=rev Author: rvos Date: 2010-01-15 17:19:50 +0000 (Fri, 15 Jan 2010) Log Message: ----------- Now stores access denied explicitly in session. Modified Paths: -------------- trunk/treebase-web/src/main/java/org/cipres/treebase/web/Constants.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/BaseFormController.java Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/Constants.java =================================================================== --- trunk/treebase-web/src/main/java/org/cipres/treebase/web/Constants.java 2010-01-15 17:09:07 UTC (rev 461) +++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/Constants.java 2010-01-15 17:19:50 UTC (rev 462) @@ -26,6 +26,7 @@ */ public static final String X_ACCESS_CODE = "x-access-code"; public static final String REVIEWER_ACCESS_GRANTED = "reviewerAccessGranted"; + public static final String REVIEWER_ACCESS_DENIED = "reviewerAccessDenied"; public static final String STUDY_MAP = "studyMap"; public static final String ANALYSIS_MAP = "analysisMap"; Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/BaseFormController.java =================================================================== --- trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/BaseFormController.java 2010-01-15 17:09:07 UTC (rev 461) +++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/BaseFormController.java 2010-01-15 17:19:50 UTC (rev 462) @@ -179,11 +179,6 @@ } private boolean isReviewerAccessGranted(HttpServletRequest pRequest) { - if ( "cancel".equals(pRequest.getParameter("agreement")) ) { - pRequest.getSession().setAttribute(Constants.REVIEWER_ACCESS_GRANTED, false); - pRequest.getSession().setAttribute("displayAgreement",true); - return false; - } boolean reviewerAccessGranted = false; Object xAccesCodeObject = pRequest.getSession().getAttribute(Constants.X_ACCESS_CODE); if ( xAccesCodeObject != null ) { @@ -209,6 +204,7 @@ pRequest.getSession().setAttribute("displayAgreement",false); } pRequest.getSession().setAttribute(Constants.REVIEWER_ACCESS_GRANTED, reviewerAccessGranted); + pRequest.getSession().removeAttribute(Constants.REVIEWER_ACCESS_DENIED); } else { LOGGER.info("x-access-code doesn't match computed hashed study id"); @@ -218,6 +214,12 @@ else { LOGGER.info("No x-access-code parameter supplied"); } + if ( "cancel".equals(pRequest.getParameter("agreement")) || pRequest.getSession().getAttribute(Constants.REVIEWER_ACCESS_DENIED) != null) { + pRequest.getSession().setAttribute(Constants.REVIEWER_ACCESS_GRANTED, false); + pRequest.getSession().setAttribute("displayAgreement",true); + pRequest.getSession().setAttribute(Constants.REVIEWER_ACCESS_DENIED, true); + return false; + } return reviewerAccessGranted; } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
[Treebase-guts] SF.net SVN: treebase:[465]
trunk/treebase-web/src/main/java/org/cipres/ treebase/web
From: <rv...@us...> - 2010-01-15 18:16:55
|
Revision: 465 http://treebase.svn.sourceforge.net/treebase/?rev=465&view=rev Author: rvos Date: 2010-01-15 18:16:45 +0000 (Fri, 15 Jan 2010) Log Message: ----------- Refactoring reviewer login logic Modified Paths: -------------- trunk/treebase-web/src/main/java/org/cipres/treebase/web/Constants.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/BaseFormController.java Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/Constants.java =================================================================== --- trunk/treebase-web/src/main/java/org/cipres/treebase/web/Constants.java 2010-01-15 18:00:16 UTC (rev 464) +++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/Constants.java 2010-01-15 18:16:45 UTC (rev 465) @@ -25,8 +25,7 @@ * objects to be stores in the session */ public static final String X_ACCESS_CODE = "x-access-code"; - public static final String REVIEWER_ACCESS_GRANTED = "reviewerAccessGranted"; - public static final String REVIEWER_ACCESS_DENIED = "reviewerAccessDenied"; + public static final String REVIEWER_AGREEMENT_ACCEPTED = "reviewerAgreementAccepted"; public static final String STUDY_MAP = "studyMap"; public static final String ANALYSIS_MAP = "analysisMap"; Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/BaseFormController.java =================================================================== --- trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/BaseFormController.java 2010-01-15 18:00:16 UTC (rev 464) +++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/BaseFormController.java 2010-01-15 18:16:45 UTC (rev 465) @@ -10,6 +10,7 @@ import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; +import javax.servlet.http.HttpSession; import org.apache.log4j.Logger; import org.cipres.treebase.NamespacedGUID; @@ -178,33 +179,33 @@ } } - private boolean isReviewerAccessGranted(HttpServletRequest pRequest) { - boolean reviewerAccessGranted = false; - if ( "cancel".equals(pRequest.getParameter("agreement")) ) { - pRequest.getSession().setAttribute(Constants.REVIEWER_ACCESS_GRANTED, false); + private boolean isReviewerAccessGranted(HttpServletRequest req) { + boolean passedHashedIDCheck = false; + HttpSession session = req.getSession(); + if ( "cancel".equals(req.getParameter("agreement")) ) { + session.setAttribute(Constants.REVIEWER_AGREEMENT_ACCEPTED, false); } - if ( "ok".equals(pRequest.getParameter("agreement")) ) { - pRequest.getSession().setAttribute(Constants.REVIEWER_ACCESS_GRANTED, true); + if ( "ok".equals(req.getParameter("agreement")) ) { + session.setAttribute(Constants.REVIEWER_AGREEMENT_ACCEPTED, true); } - Object xAccesCodeObject = pRequest.getSession().getAttribute(Constants.X_ACCESS_CODE); + Object xAccesCodeObject = session.getAttribute(Constants.X_ACCESS_CODE); if ( xAccesCodeObject != null ) { - String storedHashedStudyId = xAccesCodeObject.toString(); - TreebaseIDString tbidstr = new TreebaseIDString(Study.class,Long.parseLong(pRequest.getParameter("id"))); - if ( storedHashedStudyId.equals(tbidstr.getNamespacedGUID().getHashedIDString()) ) { - Object accessGranted = pRequest.getSession().getAttribute(Constants.REVIEWER_ACCESS_GRANTED); - if ( accessGranted == null || ((Boolean)accessGranted).booleanValue() == false ) { - LOGGER.info("Going to display agreement"); - pRequest.getSession().setAttribute("displayAgreement",true); + String suppliedHashedID = xAccesCodeObject.toString(); + TreebaseIDString tbidstr = new TreebaseIDString(Study.class,Long.parseLong(req.getParameter("id"))); + if ( suppliedHashedID.equals(tbidstr.getNamespacedGUID().getHashedIDString()) ) { + passedHashedIDCheck = true; + Object agreementAccepted = session.getAttribute(Constants.REVIEWER_AGREEMENT_ACCEPTED); + if ( agreementAccepted == null || ((Boolean)agreementAccepted).booleanValue() == false ) { + LOGGER.info("Going to display agreement - agreement acceptance: "+agreementAccepted); + session.setAttribute("displayAgreement",true); } else { - LOGGER.info("Reviewer access is granted"); - reviewerAccessGranted = true; - pRequest.getSession().setAttribute("displayAgreement",false); - } - pRequest.getSession().setAttribute(Constants.REVIEWER_ACCESS_GRANTED, reviewerAccessGranted); + LOGGER.info("Not displaying agreement"); + session.setAttribute("displayAgreement",false); + } } } - return reviewerAccessGranted; + return passedHashedIDCheck; } protected ModelAndView setAttributeAndShowForm( This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
[Treebase-guts] SF.net SVN: treebase:[733]
trunk/treebase-web/src/main/java/org/cipres/ treebase/web
From: <yo...@us...> - 2010-07-14 20:45:18
|
Revision: 733 http://treebase.svn.sourceforge.net/treebase/?rev=733&view=rev Author: youjun Date: 2010-07-14 20:45:11 +0000 (Wed, 14 Jul 2010) Log Message: ----------- handshaking controller and util Modified Paths: -------------- trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ProcessUserController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/StudyFormController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/CitationParser.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/DryadUtil.java Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ProcessUserController.java =================================================================== --- trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ProcessUserController.java 2010-07-14 02:16:55 UTC (rev 732) +++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ProcessUserController.java 2010-07-14 20:45:11 UTC (rev 733) @@ -21,11 +21,7 @@ public ModelAndView handleRequest(HttpServletRequest request, HttpServletResponse response) throws Exception { - String importKey = null; - if(request.getParameter("importKey") != null){ - importKey = (String)request.getAttribute("importKey"); - request.getSession().setAttribute("importKey",importKey); - } + String importKey = (String)request.getSession().getAttribute("importKey"); if (importKey != null && importKey.length()>0) { Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/StudyFormController.java =================================================================== --- trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/StudyFormController.java 2010-07-14 02:16:55 UTC (rev 732) +++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/StudyFormController.java 2010-07-14 20:45:11 UTC (rev 733) @@ -25,6 +25,7 @@ import org.cipres.treebase.domain.study.SubmissionService; import org.cipres.treebase.web.Constants; import org.cipres.treebase.web.model.MyProgressionListener; +import org.cipres.treebase.web.util.CitationParser; import org.cipres.treebase.web.util.ControllerUtil; import org.cipres.treebase.web.util.DryadUtil; @@ -106,28 +107,7 @@ String importKey = (String)request.getSession().getAttribute("importKey"); request.getSession().removeAttribute("importKey"); - if (request.getParameter(ACTION_SUBMIT) != null) { - // Study must be submitted with citation together - // here we are just saving the data to the session - // request.getSession().setAttribute(Constants.STUDY_KEY, study); - - // BeanUtils.copyProperties(citationCommand.getCitationMap(citationType), - // citationCommand); - - // FIXME citation - // Citation c = new ArticleCitation(); - // c.setStudy(study); - // study.setCitation(c); - - // retrieve Study object from session to be submitted with citation - // Study study = (Study) request.getSession().getAttribute(Constants.STUDY_KEY); - // citationCommand.getCitationMap(citationType).setStudy(study); - Submission submission = mSubmissionService.createSubmission(user, study); - - // save Study object to session and remove - ControllerUtil.saveStudy(request, submission.getStudy()); - - } else if(importKey != null && importKey.length()>0){ + if(importKey != null && importKey.length()>0){ String uploadpath = getServletContext() .getRealPath(TreebaseUtil.FILESEP + "DryadFileUpload") + TreebaseUtil.FILESEP + importKey; @@ -149,13 +129,14 @@ try{ Submission submission = mSubmissionService.createSubmission(user, new Study()); - Citation citation = DryadUtil.createCitation(dataPath); + CitationParser cparser= new CitationParser(dataPath); + Citation citation = cparser.getCitation(); submission.getStudy().setCitation(citation); citation.setStudy(submission.getStudy()); Collection<File> files = DryadUtil.getDataFiles(dataPath); MyProgressionListener listener = new MyProgressionListener(); - getSubmissionService().addNexusFilesJDBC(submission, files, listener); + //getSubmissionService().addNexusFilesJDBC(submission, files, listener); // save Study object to session ControllerUtil.saveStudy(request, submission.getStudy()); importStatus = "OK"; @@ -167,7 +148,32 @@ //request.getSession().removeAttribute("importKey"); return new ModelAndView(new RedirectView("submissionList.html")); - }else if (request.getParameter(ACTION_UPDATE) != null) { + } + + + + if (request.getParameter(ACTION_SUBMIT) != null) { + // Study must be submitted with citation together + // here we are just saving the data to the session + // request.getSession().setAttribute(Constants.STUDY_KEY, study); + + // BeanUtils.copyProperties(citationCommand.getCitationMap(citationType), + // citationCommand); + + // FIXME citation + // Citation c = new ArticleCitation(); + // c.setStudy(study); + // study.setCitation(c); + + // retrieve Study object from session to be submitted with citation + // Study study = (Study) request.getSession().getAttribute(Constants.STUDY_KEY); + // citationCommand.getCitationMap(citationType).setStudy(study); + Submission submission = mSubmissionService.createSubmission(user, study); + + // save Study object to session and remove + ControllerUtil.saveStudy(request, submission.getStudy()); + + } else if (request.getParameter(ACTION_UPDATE) != null) { mStudyService.update(study); } else if (request.getParameter(ACTION_DELETE) != null) { @@ -208,6 +214,10 @@ request.getSession().removeAttribute(Constants.STUDY_MAP); return new Study(); } + + if(request.getSession().getAttribute("importKey") != null) + return new Study(); + // if we are updating a data that's already in the db (access from RHS menu) study = ControllerUtil.findStudy(request, mStudyService); return study; Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/CitationParser.java =================================================================== --- trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/CitationParser.java 2010-07-14 02:16:55 UTC (rev 732) +++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/CitationParser.java 2010-07-14 20:45:11 UTC (rev 733) @@ -3,6 +3,7 @@ import java.io.File; import java.util.List; +import org.cipres.treebase.domain.admin.Person; import org.cipres.treebase.domain.study.ArticleCitation; import org.cipres.treebase.domain.study.Citation; import org.dom4j.Document; @@ -14,21 +15,18 @@ import org.dom4j.io.SAXReader; public class CitationParser { - + private ArticleCitation citation; private static final Namespace xs = new Namespace("xs","http://www.w3.org/2001/XMLSchema"); private static final Namespace dwc= new Namespace("dwc", "http://rs.tdwg.org/dwc/terms/"); private static final Namespace dcterms= new Namespace("dcterms", "http://purl.org/dc/terms/"); private static final Namespace prism= new Namespace("prism", "http://prismstandard.org/namespaces/basic/2.0/"); - private ArticleCitation citation; private Element pubRoot; private Element pkgRoot; public CitationParser(File path){ - - citation = new ArticleCitation(); - + File pubFile = new File(path, "dryadpub.xml"); SAXReader pubReader = new SAXReader(); Document pubDoc= null ; @@ -52,31 +50,69 @@ e.printStackTrace(); } + citation = new ArticleCitation(); loadData(); } private void loadData(){ - - citation.setAbstract(getNode(pubRoot,"description",dcterms).getText()); - citation.setDoi(getNode(pubRoot,"identifier",dcterms).getText());; + + Node description = getNode(pubRoot,"description",dcterms); + if(description!=null)citation.setAbstract(description.getText()); - citation.setTitle(getNode(pubRoot,"title",dcterms).getText()); - citation.setIssue(getNode(pubRoot,"issueIdentifier",prism).getText()); - citation.setJournal(getNode(pubRoot,"publicationName",prism).getText()); - citation.setVolume(getNode(pubRoot,"volume",prism).getText()); - citation.setPages(getNode(pubRoot,":pageRange",prism).getText()); + Node identifier = getNode(pubRoot,"identifier",dcterms); + if(identifier!=null)citation.setDoi(identifier.getText());; - //citation.setKeywords(getNode(pubRoot,"description",dcterms).getText()); - //citation.setAuthors(pAuthors); + Node title = getNode(pubRoot,"title",dcterms); + if(title!=null)citation.setTitle(title.getText()); - //citation.setPublishYear(getNode(pubRoot,"issued",dcterms).getText()); - //citation.setPublished(getNode(pubRoot,"description",dcterms).getText()); + Node issueIdentifier = getNode(pubRoot,"issueIdentifier",prism); + if(issueIdentifier!=null)citation.setIssue(issueIdentifier.getText()); + Node publicationName = getNode(pubRoot,"publicationName",prism); + if(publicationName!=null)citation.setJournal(publicationName.getText()); + + Node volume = getNode(pubRoot,"volume",prism); + if(volume!=null)citation.setVolume(volume.getText()); + + Node pageRange = getNode(pubRoot,"pageRange",prism); + if(pageRange!=null)citation.setPages(pageRange.getText()); + + List<Node> kl = getNodes(pkgRoot,"subject",dcterms); + String keywords=""; + for(int i = 0; i<kl.size(); i++) { + keywords+= kl.get(i).getText()+","; + } + citation.setKeywords(keywords.substring(0, keywords.length()-1)); + + List<Node> al = getNodes(pubRoot,"creator",dcterms); + for(int i = 0; i<al.size(); i++) { + String []names = al.get(i).getText().split(","); + if(names.length >1 ){ + Person p = new Person (); + p.setFirstName(names[1]); + p.setLastName(names[0]); + citation.addAuthor(p); + } + } + + try{ + int issue = Integer.parseInt(getNode(pubRoot,"issued",dcterms).getText()); + citation.setPublishYear(issue); + }catch(Exception e){ + + } + + + if(getNode(pubRoot,"pubStatus",null).getText()!=null){ + if("published".compareToIgnoreCase(getNode(pubRoot,"pubStatus",null).getText())==0) + citation.setPublished(true); + else citation.setPublished(false); + } } private Node getNode(Element root, String localName, Namespace namespace){ - + if(namespace==null)return root.element(new QName(localName)); return root.element(new QName(localName, namespace)); } @@ -85,8 +121,7 @@ return root.elements(new QName(localName, namespace)); } - - public Citation getCitation() { + public ArticleCitation getCitation() { return citation; } Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/DryadUtil.java =================================================================== --- trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/DryadUtil.java 2010-07-14 02:16:55 UTC (rev 732) +++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/DryadUtil.java 2010-07-14 20:45:11 UTC (rev 733) @@ -1,7 +1,9 @@ package org.cipres.treebase.web.util; import java.io.File; +import java.io.FileFilter; import java.io.FilenameFilter; +import java.util.ArrayList; import java.util.Arrays; import java.util.Collection; import java.util.Iterator; @@ -14,41 +16,26 @@ public class DryadUtil { - - - public static Citation createCitation(File path){ - Citation citation = new Citation(); - - File f = new File(path, "citation.xml"); - SAXReader reader = new SAXReader(); - Document doc= null ; - try { - doc = reader.read(f); - } catch (DocumentException e) { - // TODO Auto-generated catch block - e.printStackTrace(); - } - Element root = doc.getRootElement(); - Element node; - for (Iterator i = root.elementIterator("author"); i.hasNext();) { - node = (Element) i.next(); - Person p = new Person(); - //node.getName(); - citation.addAuthor(p); - } - citation.setTitle(root.element("title").getName()); - - - return citation; - } - public static Collection<File> getDataFiles(File path) { // TODO Auto-generated method stub - List<File> flist=Arrays.asList(path.listFiles(new FilenameFilter() { - public boolean accept(File file, String name) { - boolean ret = !(name.endsWith("xml")); - return ret; - }})); + File[] files = path.listFiles(new FileFilter() { + public boolean accept(File file) { + return file.isDirectory(); + }}); + + List<File> flist = new ArrayList<File>(); + + for(int i=0; i<files.length; i++){ + + File[] nexus = files[i].listFiles(new FilenameFilter() { + public boolean accept(File file, String name) { + boolean ret = !(name.endsWith("nexus")); + return ret; + }}); + + if (nexus!=null && nexus.length>0) flist.addAll(Arrays.asList(nexus)); + } + return flist; } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
[Treebase-guts] SF.net SVN: treebase:[737]
trunk/treebase-web/src/main/java/org/cipres/ treebase/web
From: <yo...@us...> - 2010-07-16 01:36:28
|
Revision: 737 http://treebase.svn.sourceforge.net/treebase/?rev=737&view=rev Author: youjun Date: 2010-07-16 01:36:17 +0000 (Fri, 16 Jul 2010) Log Message: ----------- handshaking, add study name, enable parser elements without namespace Modified Paths: -------------- trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ProcessUserController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/CitationParser.java Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ProcessUserController.java =================================================================== --- trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ProcessUserController.java 2010-07-16 00:12:57 UTC (rev 736) +++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ProcessUserController.java 2010-07-16 01:36:17 UTC (rev 737) @@ -87,7 +87,7 @@ CitationParser cparser= new CitationParser(dataPath); Citation citation = cparser.getCitation(); Study study = new Study(); - + study.setName(bagitPath.getName()); study.setCitation(citation); citation.setStudy(study); Submission submission = mSubmissionService.createSubmission(user, study); Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/CitationParser.java =================================================================== --- trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/CitationParser.java 2010-07-16 00:12:57 UTC (rev 736) +++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/CitationParser.java 2010-07-16 01:36:17 UTC (rev 737) @@ -113,7 +113,7 @@ } private Node getNode(Element root, String localName, Namespace namespace){ - if(namespace==null)return root.element(new QName(localName)); + if(namespace==null)return root.element(localName); return root.element(new QName(localName, namespace)); } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
[Treebase-guts] SF.net SVN: treebase:[739]
trunk/treebase-web/src/main/java/org/cipres/ treebase/web
From: <yo...@us...> - 2010-07-20 15:12:52
|
Revision: 739 http://treebase.svn.sourceforge.net/treebase/?rev=739&view=rev Author: youjun Date: 2010-07-20 15:12:46 +0000 (Tue, 20 Jul 2010) Log Message: ----------- handshaking process nexus Modified Paths: -------------- trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ProcessUserController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/CitationParser.java Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ProcessUserController.java =================================================================== --- trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ProcessUserController.java 2010-07-16 02:32:08 UTC (rev 738) +++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ProcessUserController.java 2010-07-20 15:12:46 UTC (rev 739) @@ -96,7 +96,7 @@ for(int i=0; i<files.size(); i++ ) submission.getStudy().addNexusFile(files.get(i).getName(), "NEXUS"); MyProgressionListener listener = new MyProgressionListener(); - //getSubmissionService().addNexusFilesJDBC(submission, files, listener); + getSubmissionService().addNexusFilesJDBC(submission, files, listener); // save Study object to session //mSubmissionService.save(submission); Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/CitationParser.java =================================================================== --- trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/CitationParser.java 2010-07-16 02:32:08 UTC (rev 738) +++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/CitationParser.java 2010-07-20 15:12:46 UTC (rev 739) @@ -61,7 +61,7 @@ if(description!=null)citation.setAbstract(description.getText()); Node identifier = getNode(pubRoot,"identifier",dcterms); - if(identifier!=null)citation.setDoi(identifier.getText());; + if(identifier!=null)citation.setDoi(identifier.getText().replaceAll("doi:", "")); Node title = getNode(pubRoot,"title",dcterms); if(title!=null)citation.setTitle(title.getText()); @@ -90,7 +90,13 @@ String []names = al.get(i).getText().split(","); if(names.length >1 ){ Person p = new Person (); - p.setFirstName(names[1]); + names[1]=names[1].trim(); + if(!(names[1].contains(" ")))p.setFirstName(names[1]); + else { + + p.setFirstName(names[1].trim().substring(0,names[1].indexOf(" "))); + p.setMiddleName(names[1].trim().substring(names[1].indexOf(" "))); + } p.setLastName(names[0]); citation.addAuthor(p); } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
[Treebase-guts] SF.net SVN: treebase:[930]
trunk/treebase-web/src/main/java/org/cipres/ treebase/web
From: <hs...@us...> - 2011-07-19 19:29:45
|
Revision: 930 http://treebase.svn.sourceforge.net/treebase/?rev=930&view=rev Author: hshyket Date: 2011-07-19 19:29:36 +0000 (Tue, 19 Jul 2011) Log Message: ----------- Changing the way that Dryad submissions put data into the fields. The title of the paper in Dryad is now the study name and the dryad submission number is prefixed to the notes. The URL field is now prepopulated with the data DOI Modified Paths: -------------- trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ProcessUserController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/CitationParser.java Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ProcessUserController.java =================================================================== --- trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ProcessUserController.java 2011-07-18 21:56:02 UTC (rev 929) +++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/ProcessUserController.java 2011-07-19 19:29:36 UTC (rev 930) @@ -90,13 +90,18 @@ CitationParser cparser= new CitationParser(dataPath); Citation citation = cparser.getCitation(); Study study = new Study(); - study.setName(bagitPath.getName()); + //study.setName(bagitPath.getName()); + study.setName(citation.getTitle()); + study.setCitation(citation); citation.setStudy(study); - study.setNotes("Please enter these author names into the TreeBASE citation " + + study.setNotes(bagitPath.getName() + + ": Please enter these author names into the TreeBASE citation " + "by clicking on the highlighted \"Authors\" item in the Tool Box." + "\n\n" + citation.getAuthorsDryadNotes()); + + citation.setAuthors(null); Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/CitationParser.java =================================================================== --- trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/CitationParser.java 2011-07-18 21:56:02 UTC (rev 929) +++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/CitationParser.java 2011-07-19 19:29:36 UTC (rev 930) @@ -101,6 +101,12 @@ citation.setPages(pageStart.getText() + "-" + pageEnd.getText()); //end VG 2010-11-18 + //set the URL to use the DOI passed by Dryad + Node doiUrl = getNode(pkgRoot,"identifier",dcterms); + if (doiUrl!=null) { + citation.setURL("http://dx.doi.org/" + doiUrl.getText()); + } + List<Node> kl = getNodes(pkgRoot,"subject",dcterms); String keywords=""; for(int i = 0; i<kl.size(); i++) { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <hs...@us...> - 2012-01-03 19:36:03
|
Revision: 1007 http://treebase.svn.sourceforge.net/treebase/?rev=1007&view=rev Author: hshyket Date: 2012-01-03 19:35:57 +0000 (Tue, 03 Jan 2012) Log Message: ----------- Fixing issue where reviewer was not able to access in progress submission Modified Paths: -------------- trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/PhyloWSController.java trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/ControllerUtil.java Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/PhyloWSController.java =================================================================== --- trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/PhyloWSController.java 2011-12-16 02:33:42 UTC (rev 1006) +++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/controllers/PhyloWSController.java 2012-01-03 19:35:57 UTC (rev 1007) @@ -19,6 +19,7 @@ import org.cipres.treebase.domain.study.Study; import org.cipres.treebase.domain.study.StudyService; import org.cipres.treebase.web.Constants; +import org.cipres.treebase.web.util.ControllerUtil; /** * This class re-directs clients to one of a number of other controllers depending @@ -115,7 +116,7 @@ // output format is something else, re-direct to download services else { url = createDownloadUrl(tbID.getId(),serializationFormat,req); - if (!redirectDownload) { + if (!redirectDownload && !ControllerUtil.isReviewerAccessGranted(req, tbID)) { url = "/treebase-web/accessviolation.html"; } } Modified: trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/ControllerUtil.java =================================================================== --- trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/ControllerUtil.java 2011-12-16 02:33:42 UTC (rev 1006) +++ trunk/treebase-web/src/main/java/org/cipres/treebase/web/util/ControllerUtil.java 2012-01-03 19:35:57 UTC (rev 1007) @@ -322,6 +322,37 @@ } } return passedHashedIDCheck; - } + } + + /** + * + * This method passes an ID into the function + * + */ + public static boolean isReviewerAccessGranted(HttpServletRequest req, TreebaseIDString tbidstr ) { + boolean passedHashedIDCheck = false; + HttpSession session = req.getSession(); + + Object xAccesCodeObject = session.getAttribute(Constants.X_ACCESS_CODE); + if ( xAccesCodeObject != null ) { + String suppliedHashedID = xAccesCodeObject.toString(); + //TreebaseIDString tbidstr = new TreebaseIDString(Study.class,Long.parseLong((String) id)); + if ( suppliedHashedID.equals(tbidstr.getNamespacedGUID().getHashedIDString()) ) { + passedHashedIDCheck = true; + Object agreementAccepted = session.getAttribute(Constants.REVIEWER_AGREEMENT_ACCEPTED); + if ( agreementAccepted == null || ((Boolean)agreementAccepted).booleanValue() == false ) { + LOGGER.info("Going to display object/file: "+agreementAccepted); + session.setAttribute("displayAgreement",true); + } + else { + LOGGER.info("Not going to display object/file"); + session.setAttribute("displayAgreement",false); + } + } + } + return passedHashedIDCheck; + } + + } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |