Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorrbrooks2010-09-14 12:54:49 -0400
committerRyan D. Brooks2010-09-14 12:54:49 -0400
commit74225843949515181df78245bfcb31147a805ba9 (patch)
tree93f998f89457d9df6ef5ace11c6127216d56bb47
parentf0f991b4f728f2e7550016da91eb2e8d2c8c750c (diff)
downloadorg.eclipse.osee-74225843949515181df78245bfcb31147a805ba9.tar.gz
org.eclipse.osee-74225843949515181df78245bfcb31147a805ba9.tar.xz
org.eclipse.osee-74225843949515181df78245bfcb31147a805ba9.zip
refactor: Directly support String.format in OseeCoreException constructors
-rw-r--r--plugins/org.eclipse.osee.ats.config.demo/src/org/eclipse/osee/ats/config/demo/artifact/DemoArtifactFactory.java2
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/actions/ExportChangeReportsAction.java2
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/artifact/ATSLog.java2
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/artifact/ActionArtifact.java6
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/artifact/AtsArtifactFactory.java2
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/artifact/TaskArtifact.java2
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/artifact/TeamDefinitionArtifact.java2
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/artifact/TeamWorkFlowArtifact.java7
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/editor/SMAWorkFlowSection.java2
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/health/ValidateChangeReports.java2
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/navigate/UserSearchWorkflowSearchItem.java5
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/AtsBranchManager.java7
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/AtsFolderUtil.java2
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/AtsPriority.java2
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/Import/ExcelAtsTaskArtifactExtractor.java12
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/StateManager.java2
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/widgets/SMAState.java2
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/widgets/XCurrentStateDam.java4
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/widgets/commit/XCommitManager.java2
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/widgets/dialog/TaskResOptionDefinition.java2
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/workflow/editor/AtsWorkflowConfigEditor.java2
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/workflow/vue/Diagram.java5
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/workflow/vue/LoadAIsAndTeamsAction.java8
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/workflow/vue/VueDiagram.java10
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/workflow/vue/VueLink.java2
-rw-r--r--plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/search/GroupWorldSearchItem.java2
-rw-r--r--plugins/org.eclipse.osee.ats/support/OseeTypes_ATS.osee1
-rw-r--r--plugins/org.eclipse.osee.coverage.test/src/org/eclipse/osee/coverage/test/CoveragePackageImportTest.java12
-rw-r--r--plugins/org.eclipse.osee.coverage.test/src/org/eclipse/osee/coverage/test/SampleJavaFileParser.java3
-rw-r--r--plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/action/ConfigureCoverageMethodsAction.java4
-rw-r--r--plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/editor/CoverageEditorImportTab.java4
-rw-r--r--plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/merge/MergeItemBase.java2
-rw-r--r--plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/model/CoverageImport.java2
-rw-r--r--plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/model/CoverageItem.java2
-rw-r--r--plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/navigate/CoverageNavigateViewItems.java5
-rw-r--r--plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/vcast/CoverageDataFile.java4
-rw-r--r--plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/vcast/VCastAggregateReport.java4
-rw-r--r--plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/vcast/VCastVcp.java2
-rw-r--r--plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/vcast/VcpSourceLineFile.java2
-rw-r--r--plugins/org.eclipse.osee.define/src/org/eclipse/osee/define/blam/operation/PublishRequirements.java4
-rw-r--r--plugins/org.eclipse.osee.define/src/org/eclipse/osee/define/relation/Import/RelationImporter.java2
-rw-r--r--plugins/org.eclipse.osee.define/src/org/eclipse/osee/define/traceability/ImportTraceabilityOperation.java4
-rw-r--r--plugins/org.eclipse.osee.define/src/org/eclipse/osee/define/traceability/blam/RemoveTraceMarksFromTraceUnits.java4
-rw-r--r--plugins/org.eclipse.osee.define/src/org/eclipse/osee/define/traceability/operations/TraceUnitFromResourceOperation.java10
-rw-r--r--plugins/org.eclipse.osee.framework.access/src/org/eclipse/osee/framework/access/internal/ObjectAccessProvider.java2
-rw-r--r--plugins/org.eclipse.osee.framework.access/src/org/eclipse/osee/framework/access/internal/cm/CmAccessControlProviderImpl.java4
-rw-r--r--plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/change/ComputeNetChangeOperation.java11
-rw-r--r--plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/change/ConflictUtil.java2
-rw-r--r--plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/commit/CommitDbOperation.java4
-rw-r--r--plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/creation/CreateBranchOperation.java7
-rw-r--r--plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/ExchangeDb.java3
-rw-r--r--plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/ImportController.java2
-rw-r--r--plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/handler/BranchDataSaxHandler.java4
-rw-r--r--plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/handler/DataToSql.java4
-rw-r--r--plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/handler/DbTableSaxHandler.java3
-rw-r--r--plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/resource/ExchangeLocatorProvider.java2
-rw-r--r--plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/resource/ExchangeProvider.java2
-rw-r--r--plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/transform/ExchangeDataProcessor.java2
-rw-r--r--plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/transform/V0_9_2Transformer.java2
-rw-r--r--plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/purge/PurgeBranchOperation.java4
-rw-r--r--plugins/org.eclipse.osee.framework.core.client/src/org/eclipse/osee/framework/core/client/ClientSessionManager.java2
-rw-r--r--plugins/org.eclipse.osee.framework.core.client/src/org/eclipse/osee/framework/core/client/server/HttpRequest.java4
-rw-r--r--plugins/org.eclipse.osee.framework.core.datastore/src/org/eclipse/osee/framework/core/datastore/cache/DatabaseArtifactTypeAccessor.java8
-rw-r--r--plugins/org.eclipse.osee.framework.core.datastore/src/org/eclipse/osee/framework/core/datastore/cache/DatabaseBranchAccessor.java4
-rw-r--r--plugins/org.eclipse.osee.framework.core.datastore/src/org/eclipse/osee/framework/core/datastore/cache/DatabaseTransactionRecordAccessor.java2
-rw-r--r--plugins/org.eclipse.osee.framework.core.datastore/src/org/eclipse/osee/framework/core/datastore/schema/sql/SqlManager.java2
-rw-r--r--plugins/org.eclipse.osee.framework.core.dsl.ui.integration/src/org/eclipse/osee/framework/core/dsl/ui/integration/operations/ExcelToEMFModel.java18
-rw-r--r--plugins/org.eclipse.osee.framework.core.message/src/org/eclipse/osee/framework/core/message/ChangeItemUtil.java3
-rw-r--r--plugins/org.eclipse.osee.framework.core.message/src/org/eclipse/osee/framework/core/message/internal/DataTranslationService.java2
-rw-r--r--plugins/org.eclipse.osee.framework.core.model/src/org/eclipse/osee/framework/core/model/OseeCachingService.java2
-rw-r--r--plugins/org.eclipse.osee.framework.core.model/src/org/eclipse/osee/framework/core/model/cache/AbstractOseeCache.java12
-rw-r--r--plugins/org.eclipse.osee.framework.core.model/src/org/eclipse/osee/framework/core/model/cache/TransactionCache.java2
-rw-r--r--plugins/org.eclipse.osee.framework.core.model/src/org/eclipse/osee/framework/core/model/internal/fields/ArtifactSuperTypeField.java7
-rw-r--r--plugins/org.eclipse.osee.framework.core.model/src/org/eclipse/osee/framework/core/model/type/OseeEnumType.java8
-rw-r--r--plugins/org.eclipse.osee.framework.core.server/src/org/eclipse/osee/framework/core/server/internal/AuthenticationManager.java6
-rw-r--r--plugins/org.eclipse.osee.framework.core.server/src/org/eclipse/osee/framework/core/server/internal/InternalOseeServerInfo.java6
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/BranchType.java2
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/CacheOperation.java2
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/ConflictStatus.java2
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/ConflictType.java2
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/Function.java2
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/ModificationType.java2
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/StorageState.java2
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/TxChange.java2
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/ArtifactDoesNotExist.java6
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/AttributeDoesNotExist.java4
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/BranchDoesNotExist.java8
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/BranchMergeException.java4
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/MultipleArtifactsExist.java4
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/MultipleAttributesExist.java4
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/MultipleBranchesExist.java4
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeAccessDeniedException.java4
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeArgumentException.java4
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeAuthenticationException.java4
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeAuthenticationRequiredException.java4
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeCoreException.java14
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeDataStoreException.java4
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeInvalidInheritanceException.java4
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeNotFoundException.java18
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeStateException.java4
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeTypeDoesNotExist.java4
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeWrappedException.java4
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/TransactionDoesNotExist.java8
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/UserInDatabaseMultipleTimes.java8
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/UserNotInDatabase.java8
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/util/Conditions.java14
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/util/HttpMessage.java2
-rw-r--r--plugins/org.eclipse.osee.framework.database.init/src/org/eclipse/osee/framework/database/init/SkynetDbBranchDataImport.java7
-rw-r--r--plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/core/SupportedDatabase.java2
-rw-r--r--plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/internal/DatabaseInfoProvider.java4
-rw-r--r--plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/internal/core/ConnectionFactoryProvider.java2
-rw-r--r--plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/internal/core/OseeConnectionPoolImpl.java3
-rw-r--r--plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/internal/core/OseeDatabaseServiceImpl.java2
-rw-r--r--plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/internal/core/StatementUtil.java4
-rw-r--r--plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/operation/ConsolidateArtifactVersionTxOperation.java4
-rw-r--r--plugins/org.eclipse.osee.framework.manager.servlet/src/org/eclipse/osee/framework/manager/servlet/DataServlet.java2
-rw-r--r--plugins/org.eclipse.osee.framework.manager.servlet/src/org/eclipse/osee/framework/manager/servlet/OseeCacheServlet.java2
-rw-r--r--plugins/org.eclipse.osee.framework.manager.servlet/src/org/eclipse/osee/framework/manager/servlet/UnsubscribeTransaction.java4
-rw-r--r--plugins/org.eclipse.osee.framework.manager.servlet/src/org/eclipse/osee/framework/manager/servlet/ats/AtsResourceLocatorProvider.java2
-rw-r--r--plugins/org.eclipse.osee.framework.manager.servlet/src/org/eclipse/osee/framework/manager/servlet/ats/AtsXmlSearch.java2
-rw-r--r--plugins/org.eclipse.osee.framework.manager.servlet/src/org/eclipse/osee/framework/manager/servlet/data/DefaultOseeArtifact.java4
-rw-r--r--plugins/org.eclipse.osee.framework.messaging/src/org/eclipse/osee/framework/messaging/internal/activemq/ActiveMqUtil.java2
-rw-r--r--plugins/org.eclipse.osee.framework.resource.locator.attribute/src/org/eclipse/osee/framework/resource/locator/attribute/AttributeLocatorProvider.java2
-rw-r--r--plugins/org.eclipse.osee.framework.resource.management/src/org/eclipse/osee/framework/resource/management/exception/MalformedLocatorException.java4
-rw-r--r--plugins/org.eclipse.osee.framework.resource.management/src/org/eclipse/osee/framework/resource/management/internal/ResourceLocatorManager.java4
-rw-r--r--plugins/org.eclipse.osee.framework.resource.management/src/org/eclipse/osee/framework/resource/management/internal/ResourceManager.java2
-rw-r--r--plugins/org.eclipse.osee.framework.resource.management/src/org/eclipse/osee/framework/resource/management/util/OptionsProcessor.java2
-rw-r--r--plugins/org.eclipse.osee.framework.resource.provider.attribute/src/org/eclipse/osee/framework/resource/provider/attribute/AttributeProvider.java3
-rw-r--r--plugins/org.eclipse.osee.framework.search.engine/src/org/eclipse/osee/framework/search/engine/internal/AttributeTaggerProviderManagerImpl.java5
-rw-r--r--plugins/org.eclipse.osee.framework.server.admin/src/org/eclipse/osee/framework/server/admin/branch/BranchExportWorker.java3
-rw-r--r--plugins/org.eclipse.osee.framework.server.admin/src/org/eclipse/osee/framework/server/admin/branch/BranchImportWorker.java4
-rw-r--r--plugins/org.eclipse.osee.framework.server.admin/src/org/eclipse/osee/framework/server/admin/branch/ExchangeIntegrityWorker.java5
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core.test/src/org/eclipse/osee/framework/skynet/core/test/cases/ArtifactLoaderTest.java2
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/OseeSystemArtifacts.java4
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/UserManager.java9
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/Artifact.java24
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/ArtifactCache.java6
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/ArtifactFactory.java4
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/ArtifactPersistenceManager.java4
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/ArtifactTypeManager.java15
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/BranchManager.java8
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/BranchUtility.java6
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/PurgeArtifacts.java4
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/PurgeTransactionOperation.java9
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/RevertAction.java4
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/StaticIdManager.java4
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/UpdateMergeBranch.java4
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/factory/UserArtifactFactory.java2
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/attribute/AttributeExtensionManager.java9
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/attribute/AttributeTypeManager.java11
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/attribute/OseeEnumTypeManager.java5
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/attribute/utils/AbstractResourceProcessor.java4
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/change/AttributeChange.java3
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/conflict/AttributeConflict.java12
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/importing/operations/SourceToRoughArtifactOperation.java2
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/importing/parsers/ExcelArtifactExtractor.java5
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/importing/parsers/WordOutlineExtractor.java2
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/importing/parsers/WordOutlineExtractorDelegate.java9
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/importing/resolvers/NewArtifactImportResolver.java2
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/relation/RelationManager.java18
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/relation/RelationTypeManager.java4
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/relation/order/RelationSorterProvider.java2
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/ConflictManagerInternal.java8
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/transaction/TransactionManager.java10
-rw-r--r--plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/transaction/TransactionMonitor.java10
-rw-r--r--plugins/org.eclipse.osee.framework.ui.data.model.editor/src/org/eclipse/osee/framework/ui/data/model/editor/model/ArtifactDataType.java4
-rw-r--r--plugins/org.eclipse.osee.framework.ui.plugin/src/org/eclipse/osee/framework/ui/plugin/OseeUiActions.java8
-rw-r--r--plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/ArtifactExplorer.java6
-rw-r--r--plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/XWidgetParser.java2
-rw-r--r--plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/artifact/annotation/AnnotationComposite.java2
-rw-r--r--plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/blam/DynamicBlamOperation.java11
-rw-r--r--plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/blam/VariableMap.java11
-rw-r--r--plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/blam/operation/ConsolidateRelationsTxOperation.java2
-rw-r--r--plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/blam/operation/SetRequirementCategory.java2
-rw-r--r--plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/FileSystemRenderer.java3
-rw-r--r--plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/NativeRenderer.java4
-rw-r--r--plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/RendererManager.java6
-rw-r--r--plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/RenderingUtil.java2
-rw-r--r--plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/UpdateArtifactOperation.java6
-rw-r--r--plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/WholeWordRenderer.java3
-rw-r--r--plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/WordmlPicture.java8
-rw-r--r--plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/word/WordTemplateFileDiffer.java4
-rw-r--r--plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/word/WordTemplateProcessor.java3
-rw-r--r--plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/results/ResultsEditorConverter.java20
-rw-r--r--plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/templates/ArtifactTemplateProvider.java8
-rw-r--r--plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/widgets/XSelectFromDialog.java4
-rw-r--r--plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/widgets/workflow/WorkFlowDefinition.java8
-rw-r--r--plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/widgets/workflow/WorkFlowDefinitionFactory.java3
-rw-r--r--plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/widgets/workflow/WorkItemDefinitionFactory.java4
-rw-r--r--plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/widgets/workflow/XWidgetFactory.java11
-rw-r--r--plugins/org.eclipse.osee.ote.define/src/org/eclipse/osee/ote/define/artifacts/TestRunOperator.java4
-rw-r--r--plugins/org.eclipse.osee.ote.define/src/org/eclipse/osee/ote/define/operations/ImportOutfileOperation.java4
-rw-r--r--plugins/org.eclipse.osee.ote.define/src/org/eclipse/osee/ote/define/utilities/OutfileParserExtensionManager.java3
-rw-r--r--plugins/org.eclipse.osee.ote.message/META-INF/MANIFEST.MF2
-rw-r--r--plugins/org.eclipse.osee.ote.message/src/org/eclipse/osee/ote/message/tool/AbstractMessageToolService.java5
-rw-r--r--plugins/org.eclipse.osee.ote.message/src/org/eclipse/osee/ote/message/tool/rec/IMessageEntryFactory.java3
-rw-r--r--plugins/org.eclipse.osee.ote.message/src/org/eclipse/osee/ote/message/tool/rec/MessageRecorder.java5
-rw-r--r--plugins/org.eclipse.osee.ote.message/src/org/eclipse/osee/ote/message/tool/rec/entry/MessageRecEntry.java6
-rw-r--r--plugins/org.eclipse.osee.ote.ui.define/src/org/eclipse/osee/ote/ui/define/dialogs/ReportsDialog.java4
-rw-r--r--plugins/org.eclipse.osee.ote.ui.define/src/org/eclipse/osee/ote/ui/define/reports/output/OutputFactory.java13
-rw-r--r--plugins/org.eclipse.osee.ote.ui.define/src/org/eclipse/osee/ote/ui/define/viewers/actions/EditDispositionAction.java4
-rw-r--r--plugins/org.eclipse.osee.ote.ui.define/src/org/eclipse/osee/ote/ui/define/viewers/actions/OpenInArtifactEditor.java4
-rw-r--r--plugins/org.eclipse.osee.ote.ui.message/META-INF/MANIFEST.MF3
-rw-r--r--plugins/org.eclipse.osee.ote.ui.message/src/org/eclipse/osee/ote/ui/message/watch/WatchView.java20
-rw-r--r--plugins/org.eclipse.osee.support.test.util/src/org/eclipse/osee/support/test/util/TestUtil.java4
205 files changed, 481 insertions, 526 deletions
diff --git a/plugins/org.eclipse.osee.ats.config.demo/src/org/eclipse/osee/ats/config/demo/artifact/DemoArtifactFactory.java b/plugins/org.eclipse.osee.ats.config.demo/src/org/eclipse/osee/ats/config/demo/artifact/DemoArtifactFactory.java
index fbb838b48a..bffdb0cfc0 100644
--- a/plugins/org.eclipse.osee.ats.config.demo/src/org/eclipse/osee/ats/config/demo/artifact/DemoArtifactFactory.java
+++ b/plugins/org.eclipse.osee.ats.config.demo/src/org/eclipse/osee/ats/config/demo/artifact/DemoArtifactFactory.java
@@ -41,7 +41,7 @@ public class DemoArtifactFactory extends ArtifactFactory {
if (artifactType.getName().equals(DemoReqTeamWorkflowArtifact.ARTIFACT_NAME)) {
return new DemoReqTeamWorkflowArtifact(this, guid, humandReadableId, branch, artifactType);
}
- throw new OseeArgumentException("did not recognize the artifact type: " + artifactType.getName());
+ throw new OseeArgumentException("did not recognize the artifact type [%s]", artifactType);
}
} \ No newline at end of file
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/actions/ExportChangeReportsAction.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/actions/ExportChangeReportsAction.java
index c35ae4eb0f..62522a6719 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/actions/ExportChangeReportsAction.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/actions/ExportChangeReportsAction.java
@@ -131,7 +131,7 @@ public class ExportChangeReportsAction extends Action {
}
}
if (minTransactionId == -1) {
- throw new OseeStateException("no transaction records found for " + workflow);
+ throw new OseeStateException("no transaction records found for [%s]", workflow);
}
return TransactionManager.getTransactionId(minTransactionId);
}
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/artifact/ATSLog.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/artifact/ATSLog.java
index 22b18c0730..f7c62d2f6a 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/artifact/ATSLog.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/artifact/ATSLog.java
@@ -66,7 +66,7 @@ public class ATSLog {
return (LogType) e;
}
}
- throw new OseeArgumentException("Unhandled LogType: \"" + type + "\"");
+ throw new OseeArgumentException("Unhandled LogType: [%s]", type);
}
};
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/artifact/ActionArtifact.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/artifact/ActionArtifact.java
index 0495262f32..91bf4460df 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/artifact/ActionArtifact.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/artifact/ActionArtifact.java
@@ -753,8 +753,8 @@ public class ActionArtifact extends ATSArtifact implements IWorldViewArtifact {
for (TeamWorkFlowArtifact teamArt : getTeamWorkFlowArtifacts()) {
if (teamArt.getTeamDefinition().equals(teamDef)) {
AWorkbench.popup("ERROR", "Team already exist");
- throw new OseeArgumentException(
- "Team \"" + teamDef + "\" already exists for Action " + getHumanReadableId());
+ throw new OseeArgumentException("Team [%s] already exists for Action [%s]", teamDef,
+ getHumanReadableId());
}
}
}
@@ -803,6 +803,8 @@ public class ActionArtifact extends ATSArtifact implements IWorldViewArtifact {
PriorityType priType = null;
if (Strings.isValid(priorityStr)) {
priType = PriorityType.getPriority(priorityStr);
+ } else {
+ throw new OseeArgumentException("Invalid priority [%s]", priorityStr);
}
setArtifactIdentifyData(toTeam, fromAction.getName(),
fromAction.getSoleAttributeValue(AtsAttributeTypes.Description, ""),
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/artifact/AtsArtifactFactory.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/artifact/AtsArtifactFactory.java
index c895df9098..ed97d556aa 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/artifact/AtsArtifactFactory.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/artifact/AtsArtifactFactory.java
@@ -70,7 +70,7 @@ public class AtsArtifactFactory extends ArtifactFactory {
if (artifactType.equals(AtsArtifactTypes.Goal)) {
return new GoalArtifact(this, guid, humandReadableId, branch, artifactType);
}
- throw new OseeArgumentException("did not recognize the artifact type: " + artifactType.getName());
+ throw new OseeArgumentException("did not recognize the artifact type [%s]", artifactType);
}
@Override
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/artifact/TaskArtifact.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/artifact/TaskArtifact.java
index 9e7ba3fa5d..f64f37ce5b 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/artifact/TaskArtifact.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/artifact/TaskArtifact.java
@@ -311,7 +311,7 @@ public class TaskArtifact extends StateMachineArtifact implements IATSStateMachi
Collection<StateMachineArtifact> smas =
getRelatedArtifacts(AtsRelationTypes.SmaToTask_Sma, StateMachineArtifact.class);
if (smas.isEmpty()) {
- throw new OseeStateException("Task has no parent - " + getHumanReadableId());
+ throw new OseeStateException("Task has no parent [%s]", getHumanReadableId());
}
parentSma = smas.iterator().next();
return parentSma;
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/artifact/TeamDefinitionArtifact.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/artifact/TeamDefinitionArtifact.java
index 90ba9724bf..db09a20bd0 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/artifact/TeamDefinitionArtifact.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/artifact/TeamDefinitionArtifact.java
@@ -462,7 +462,7 @@ public class TeamDefinitionArtifact extends Artifact implements ICommitConfigArt
if (!hasWorkRule(ruleId)) {
Artifact artifact = WorkItemDefinitionFactory.getWorkItemDefinitionArtifact(ruleId);
if (artifact == null) {
- throw new OseeArgumentException("Rule \"" + ruleId + "\" does not exist.");
+ throw new OseeArgumentException("Rule [%s] does not exist.", ruleId);
} else {
addRelation(CoreRelationTypes.WorkItem__Child, artifact);
}
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/artifact/TeamWorkFlowArtifact.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/artifact/TeamWorkFlowArtifact.java
index bd72fe6a9f..ae11da2ee7 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/artifact/TeamWorkFlowArtifact.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/artifact/TeamWorkFlowArtifact.java
@@ -214,8 +214,7 @@ public class TeamWorkFlowArtifact extends TaskableStateMachineArtifact implement
public TeamDefinitionArtifact getTeamDefinition() throws OseeCoreException, OseeCoreException {
String guid = this.getSoleAttributeValue(AtsAttributeTypes.TeamDefinition, "");
if (!Strings.isValid(guid)) {
- throw new OseeArgumentException(
- "TeamWorkflow [" + getHumanReadableId() + "] has no TeamDefinition associated.");
+ throw new OseeArgumentException("TeamWorkflow [%s] has no TeamDefinition associated.", getHumanReadableId());
}
return AtsCacheManager.getTeamDefinitionArtifact(guid);
}
@@ -286,9 +285,9 @@ public class TeamWorkFlowArtifact extends TaskableStateMachineArtifact implement
Collection<ActionArtifact> arts =
getRelatedArtifacts(AtsRelationTypes.ActionToWorkflow_Action, ActionArtifact.class);
if (arts.isEmpty()) {
- throw new OseeStateException("Team " + getHumanReadableId() + " has no parent Action");
+ throw new OseeStateException("Team [%s] has no parent Action", getGuid());
} else if (arts.size() > 1) {
- throw new OseeStateException("Team " + getHumanReadableId() + " has multiple parent Actions");
+ throw new OseeStateException("Team [%s] has multiple parent Actions", getGuid());
}
parentAction = arts.iterator().next();
return parentAction;
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/editor/SMAWorkFlowSection.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/editor/SMAWorkFlowSection.java
index 6e1bd70953..604510a35e 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/editor/SMAWorkFlowSection.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/editor/SMAWorkFlowSection.java
@@ -366,7 +366,7 @@ public class SMAWorkFlowSection extends SectionPart {
if (sma.isCancelled()) {
LogItem item = sma.getLog().getStateEvent(LogType.StateCancelled);
if (item == null) {
- throw new OseeStateException("ats.Log: Cancelled state has no logItem for " + sma.getHumanReadableId());
+ throw new OseeStateException("ats.Log: Cancelled state has no logItem for [%s]", sma.getGuid());
}
if (item.getState().equals(atsWorkPage.getName())) {
sb.append(" - Cancelled");
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/health/ValidateChangeReports.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/health/ValidateChangeReports.java
index aceabaa6d8..a637ffc2f0 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/health/ValidateChangeReports.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/health/ValidateChangeReports.java
@@ -221,7 +221,7 @@ public class ValidateChangeReports extends XNavigateItemAction {
String storedChangeReport = null;
Artifact artifactForStore = null;
if (arts.size() > 1) {
- throw new OseeStateException("Multiple artifacts found of name \"" + name + "\"");
+ throw new OseeStateException("Multiple artifacts found named [%s]", name);
} else if (arts.size() == 1) {
artifactForStore = arts.iterator().next();
storedChangeReport = artifactForStore.getSoleAttributeValue(CoreAttributeTypes.GeneralStringData, null);
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/navigate/UserSearchWorkflowSearchItem.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/navigate/UserSearchWorkflowSearchItem.java
index a352c27cc3..0faf4d3209 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/navigate/UserSearchWorkflowSearchItem.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/navigate/UserSearchWorkflowSearchItem.java
@@ -24,6 +24,7 @@ import org.eclipse.osee.ats.world.WorldEditorParameterSearchItem;
import org.eclipse.osee.ats.world.search.UserWorldSearchItem;
import org.eclipse.osee.ats.world.search.UserWorldSearchItem.UserSearchOption;
import org.eclipse.osee.framework.core.exception.OseeCoreException;
+import org.eclipse.osee.framework.core.exception.OseeStateException;
import org.eclipse.osee.framework.jdk.core.util.Strings;
import org.eclipse.osee.framework.logging.OseeLevel;
import org.eclipse.osee.framework.logging.OseeLog;
@@ -257,7 +258,7 @@ public class UserSearchWorkflowSearchItem extends WorldEditorParameterSearchItem
}
}
- public void setSelected(UserSearchOption userSearchOption, boolean set) {
+ public void setSelected(UserSearchOption userSearchOption, boolean set) throws OseeStateException {
if (userSearchOption == UserSearchOption.Assignee) {
assigneeCheckbox.set(set);
} else if (userSearchOption == UserSearchOption.Favorites) {
@@ -277,7 +278,7 @@ public class UserSearchWorkflowSearchItem extends WorldEditorParameterSearchItem
} else if (userSearchOption == UserSearchOption.IncludeTasks) {
tasksCheckbox.set(set);
} else {
- throw new IllegalStateException(String.format("Unhandled checkbox [%s]", userSearchOption));
+ throw new OseeStateException("Unhandled checkbox [%s]", userSearchOption);
}
}
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/AtsBranchManager.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/AtsBranchManager.java
index 2a12cc0b01..1103092f02 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/AtsBranchManager.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/AtsBranchManager.java
@@ -499,7 +499,8 @@ public class AtsBranchManager {
return null;
} else if (branches.size() > 1) {
throw new MultipleBranchesExist(
- "Unexpected multiple associated un-deleted working branches found for workflow " + teamArt.getHumanReadableId());
+ "Unexpected multiple associated un-deleted working branches found for workflow [%s]",
+ teamArt.getHumanReadableId());
} else {
return branches.get(0);
}
@@ -661,7 +662,7 @@ public class AtsBranchManager {
public static void createNecessaryBranchEventReviews(StateEventType stateEventType, TeamWorkFlowArtifact teamArt, SkynetTransaction transaction) throws OseeCoreException {
if (stateEventType != StateEventType.CommitBranch && stateEventType != StateEventType.CreateBranch) {
- throw new OseeStateException("Invalid stateEventType = " + stateEventType);
+ throw new OseeStateException("Invalid stateEventType [%s]", stateEventType);
}
// Create any decision and peerToPeer reviews for createBranch and commitBranch
for (String ruleId : Arrays.asList(AtsAddDecisionReviewRule.ID, AtsAddPeerToPeerReviewRule.ID)) {
@@ -766,7 +767,7 @@ public class AtsBranchManager {
*/
public ChangeData getChangeData(ICommitConfigArtifact commitConfigArt) throws OseeCoreException {
if (commitConfigArt != null && commitConfigArt.getParentBranch() == null) {
- throw new OseeArgumentException("Parent Branch not configured for " + commitConfigArt);
+ throw new OseeArgumentException("Parent Branch not configured for [%s]", commitConfigArt);
}
Collection<Change> changes = new ArrayList<Change>();
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/AtsFolderUtil.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/AtsFolderUtil.java
index 0bdfd741de..31d4dd329a 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/AtsFolderUtil.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/AtsFolderUtil.java
@@ -68,7 +68,7 @@ public class AtsFolderUtil {
StaticIdManager.getSingletonArtifact(atsFolder.artifactType, atsFolder.staticId, AtsUtil.getAtsBranch(),
true);
if (artifact == null) {
- throw new OseeStateException(String.format("Can't retrieve Ats folder [%s]", atsFolder.displayName));
+ throw new OseeStateException("Can't retrieve Ats folder [%s]", atsFolder.displayName);
}
folderMap.put(atsFolder, artifact);
}
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/AtsPriority.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/AtsPriority.java
index d172dcf985..8f503b5d93 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/AtsPriority.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/AtsPriority.java
@@ -74,7 +74,7 @@ public class AtsPriority {
return pri;
}
}
- throw new OseeStateException("Invalid priority => " + type);
+ throw new OseeStateException("Invalid priority [%s]", type);
}
};
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/Import/ExcelAtsTaskArtifactExtractor.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/Import/ExcelAtsTaskArtifactExtractor.java
index 26357f43bb..1a9c91149b 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/Import/ExcelAtsTaskArtifactExtractor.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/Import/ExcelAtsTaskArtifactExtractor.java
@@ -234,8 +234,8 @@ public class ExcelAtsTaskArtifactExtractor {
percent = percent * 100;
}
} catch (Exception ex) {
- throw new OseeArgumentException(String.format("Invalid Percent Complete \"%s\" for row %d",
- str, rowNum));
+ throw new OseeArgumentException("Invalid Percent Complete \"%s\" for row %d",
+ str, rowNum);
}
int percentInt = percent.intValue();
sma.getStateMgr().updateMetrics(0, percentInt, true);
@@ -247,8 +247,8 @@ public class ExcelAtsTaskArtifactExtractor {
try {
hours = new Double(str);
} catch (Exception ex) {
- throw new OseeArgumentException(String.format("Invalid Hours Spent \"%s\" for row %d", str,
- rowNum));
+ throw new OseeArgumentException("Invalid Hours Spent \"%s\" for row %d", str,
+ rowNum);
}
sma.getStateMgr().updateMetrics(hours, sma.getStateMgr().getPercentComplete(), true);
}
@@ -259,8 +259,8 @@ public class ExcelAtsTaskArtifactExtractor {
try {
hours = new Double(str);
} catch (Exception ex) {
- throw new OseeArgumentException(String.format("Invalid Estimated Hours \"%s\" for row %d", str,
- rowNum));
+ throw new OseeArgumentException("Invalid Estimated Hours \"%s\" for row %d", str,
+ rowNum);
}
taskArt.setSoleAttributeValue(AtsAttributeTypes.EstimatedHours, hours);
}
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/StateManager.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/StateManager.java
index 8887323e66..dae9ec2f78 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/StateManager.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/StateManager.java
@@ -183,7 +183,7 @@ public class StateManager {
*/
public void setAssignee(String stateName, User assignee) throws OseeCoreException {
if (!isStateVisited(stateName)) {
- throw new OseeArgumentException("State " + stateName + " does not exist.");
+ throw new OseeArgumentException("State [%s] does not exist.", stateName);
}
SMAState state = getSMAState(stateName, false);
state.setAssignee(assignee);
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/widgets/SMAState.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/widgets/SMAState.java
index 8dd8875ac3..48db5005ac 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/widgets/SMAState.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/widgets/SMAState.java
@@ -189,7 +189,7 @@ public class SMAState {
}
assignees = UsersByIds.getUsers(m.group(2));
} else {
- throw new OseeArgumentException("Can't unpack state data => " + xml);
+ throw new OseeArgumentException("Can't unpack state data [%s]", xml);
}
}
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/widgets/XCurrentStateDam.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/widgets/XCurrentStateDam.java
index 358d020a02..7c8cf4329d 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/widgets/XCurrentStateDam.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/widgets/XCurrentStateDam.java
@@ -37,8 +37,8 @@ public class XCurrentStateDam extends XStateAssigneesDam {
public SMAState getState() throws OseeCoreException {
Set<SMAState> states = getStates();
if (states.size() != 1) {
- throw new OseeArgumentException(
- "Must be one current state. Found " + states.size() + " for " + getArtifact().getGuid());
+ throw new OseeArgumentException("Must be one current state. Found %d for %s", states.size(),
+ getArtifact().getGuid());
}
return states.iterator().next();
}
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/widgets/commit/XCommitManager.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/widgets/commit/XCommitManager.java
index 7d2baf4161..e5768c78a1 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/widgets/commit/XCommitManager.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/widgets/commit/XCommitManager.java
@@ -355,7 +355,7 @@ public class XCommitManager extends XWidget implements IArtifactWidget, IBranchE
@Override
public void setArtifact(Artifact artifact) throws OseeCoreException {
if (!(artifact instanceof TeamWorkFlowArtifact)) {
- throw new OseeStateException("Must be TeamWorkflowArtifact, set was a " + artifact.getArtifactTypeName());
+ throw new OseeStateException("Must be TeamWorkflowArtifact, set was a [%s]", artifact.getArtifactTypeName());
}
this.teamArt = (TeamWorkFlowArtifact) artifact;
loadTable();
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/widgets/dialog/TaskResOptionDefinition.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/widgets/dialog/TaskResOptionDefinition.java
index 4447ed2a30..cd821e3d6c 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/widgets/dialog/TaskResOptionDefinition.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/util/widgets/dialog/TaskResOptionDefinition.java
@@ -63,7 +63,7 @@ public class TaskResOptionDefinition {
} else if (nodeName.equals(Field.percent.name())) {
percent = node.getNodeValue();
} else {
- throw new OseeArgumentException("Unknow Task Resolution Option Attribute \"" + nodeName + "\"");
+ throw new OseeArgumentException("Unknow Task Resolution Option Attribute [%s]", nodeName);
}
}
}
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/workflow/editor/AtsWorkflowConfigEditor.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/workflow/editor/AtsWorkflowConfigEditor.java
index 5da7626ac1..0afef5de62 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/workflow/editor/AtsWorkflowConfigEditor.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/workflow/editor/AtsWorkflowConfigEditor.java
@@ -249,7 +249,7 @@ public class AtsWorkflowConfigEditor extends GraphicalEditorWithFlyoutPalette im
int yLoc = 0;
WorkPageDefinition startPage = workflowDef.getStartPage();
if (startPage == null || startPage.getName().equals("")) {
- throw new OseeArgumentException("StartPage null for workflow " + workflowDef);
+ throw new OseeArgumentException("StartPage null for workflow [%s]", workflowDef);
}
// Create states
List<WorkPageDefinition> pages = workflowDef.getPagesOrdered();
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/workflow/vue/Diagram.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/workflow/vue/Diagram.java
index e097a9c3e5..c7dafc0db6 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/workflow/vue/Diagram.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/workflow/vue/Diagram.java
@@ -49,8 +49,7 @@ public class Diagram {
public DiagramNode getPage(String pageName) throws OseeCoreException {
List<DiagramNode> pages = getPages(pageName);
if (pages.size() > 1) {
- throw new OseeArgumentException(
- "Multiple node of same name found in workflow => " + getId() + " Use getPages.");
+ throw new OseeArgumentException("Multiple node of same name found in workflow [%s]. Use getPages.", getId());
}
return pages.iterator().next();
}
@@ -63,7 +62,7 @@ public class Diagram {
}
}
if (foundPages.isEmpty()) {
- throw new OseeArgumentException("Invalid node Name \"" + pageName + "\" from workflow => " + getId());
+ throw new OseeArgumentException("Invalid node Name [%s] from workflow [%s]", pageName, getId());
}
return foundPages;
}
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/workflow/vue/LoadAIsAndTeamsAction.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/workflow/vue/LoadAIsAndTeamsAction.java
index 99c2c215fb..a120b63f44 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/workflow/vue/LoadAIsAndTeamsAction.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/workflow/vue/LoadAIsAndTeamsAction.java
@@ -208,8 +208,8 @@ public class LoadAIsAndTeamsAction {
User u = getUserByName(name, allowUserCreation, transaction);
members.add(u);
} else {
- throw new OseeArgumentException(
- "Unhandled AtsConfig Line\"" + line + "\" in diagram page \"" + page.getName() + "\"");
+ throw new OseeArgumentException("Unhandled AtsConfig Line [%s] in diagram page [%s]", line,
+ page.getName());
}
}
}
@@ -222,8 +222,8 @@ public class LoadAIsAndTeamsAction {
if (actItem != null) {
actionableItems.add(actItem);
} else {
- throw new OseeArgumentException(
- "Can't retrieve Actionable Item \"" + childPage.getName() + "\" with id " + childPage.getId());
+ throw new OseeArgumentException("Can't retrieve Actionable Item [%s] with id [%s]",
+ childPage.getName(), childPage.getId());
}
}
}
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/workflow/vue/VueDiagram.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/workflow/vue/VueDiagram.java
index 44f3d8801e..a3ed6ee5c1 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/workflow/vue/VueDiagram.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/workflow/vue/VueDiagram.java
@@ -54,12 +54,12 @@ public class VueDiagram {
for (VueLink link : links) {
VueNode fromVuePage = getPageFromVueId(link.getFromVueId());
if (fromVuePage == null) {
- throw new OseeArgumentException("Can't retrieve fromVuePage with id " + link.getFromVueId());
+ throw new OseeArgumentException("Can't retrieve fromVuePage with id [%s]", link.getFromVueId());
}
VueNode toVuePage = getPageFromVueId(link.getToVueId());
if (toVuePage == null) {
- throw new OseeArgumentException(
- "Can't retrieve toVuePage " + link.getToVueId() + " fromVuePage " + link.getFromVueId() + " named \"" + fromVuePage.getWorkPage().getName() + "\"");
+ throw new OseeArgumentException("Can't retrieve toVuePage [%s] fromVuePage [%s] named [%s]",
+ link.getToVueId(), link.getFromVueId(), fromVuePage.getWorkPage().getName());
}
fromVuePage.getWorkPage().addToPage(toVuePage.getWorkPage(), link.getName().equals("return"));
toVuePage.getWorkPage().addFromPage(fromVuePage.getWorkPage());
@@ -71,8 +71,8 @@ public class VueDiagram {
if (fromVuePage.getWorkPage().getDefaultToPage() == null) {
fromVuePage.getWorkPage().setDefaultToPage(toVuePage.getWorkPage());
} else {
- throw new OseeArgumentException(
- "Can't have 2 default transitions. Page " + fromVuePage.getWorkPage().getName());
+ throw new OseeArgumentException("Can't have 2 default transitions. Page [%s]",
+ fromVuePage.getWorkPage().getName());
}
}
}
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/workflow/vue/VueLink.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/workflow/vue/VueLink.java
index 76cf34dbf7..438cfd2db0 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/workflow/vue/VueLink.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/workflow/vue/VueLink.java
@@ -49,7 +49,7 @@ public class VueLink {
toVueId = m.group(2);
multiDirectional = true;
} else if (xml.contains("arrowState=\"0\"")) {
- throw new OseeArgumentException("Non-directional links not supported. id = " + getVueId());
+ throw new OseeArgumentException("Non-directional links not supported. id [%s]", getVueId());
}
}
}
diff --git a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/search/GroupWorldSearchItem.java b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/search/GroupWorldSearchItem.java
index 24c0234df8..40745af120 100644
--- a/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/search/GroupWorldSearchItem.java
+++ b/plugins/org.eclipse.osee.ats/src/org/eclipse/osee/ats/world/search/GroupWorldSearchItem.java
@@ -79,7 +79,7 @@ public class GroupWorldSearchItem extends WorldUISearchItem {
group = UniversalGroup.getGroups(groupName, branch).iterator().next();
}
if (group == null) {
- throw new OseeArgumentException("Can't Find Universal Group for " + getName());
+ throw new OseeArgumentException("Can't Find Universal Group for [%s]", getName());
}
}
diff --git a/plugins/org.eclipse.osee.ats/support/OseeTypes_ATS.osee b/plugins/org.eclipse.osee.ats/support/OseeTypes_ATS.osee
index a3084ee422..32d1b5a8f0 100644
--- a/plugins/org.eclipse.osee.ats/support/OseeTypes_ATS.osee
+++ b/plugins/org.eclipse.osee.ats/support/OseeTypes_ATS.osee
@@ -464,7 +464,6 @@ attributeType "ats.Action Details Format" extends StringAttribute {
dataProvider DefaultAttributeDataProvider
min 0
max 1
- taggerId DefaultAttributeTaggerProvider
}
attributeType "ats.Actionable Item" extends StringAttribute {
diff --git a/plugins/org.eclipse.osee.coverage.test/src/org/eclipse/osee/coverage/test/CoveragePackageImportTest.java b/plugins/org.eclipse.osee.coverage.test/src/org/eclipse/osee/coverage/test/CoveragePackageImportTest.java
index b25b9de79e..2f6895d5a9 100644
--- a/plugins/org.eclipse.osee.coverage.test/src/org/eclipse/osee/coverage/test/CoveragePackageImportTest.java
+++ b/plugins/org.eclipse.osee.coverage.test/src/org/eclipse/osee/coverage/test/CoveragePackageImportTest.java
@@ -741,7 +741,7 @@ public class CoveragePackageImportTest {
} else if (mergeItem.getMergeType() == MergeType.Moved_Due_To_Delete) {
numMoveDueToDelete++;
} else {
- throw new OseeStateException("Unexpected merge type for Delete" + mergeItem.getMergeType());
+ throw new OseeStateException("Unexpected merge type for Delete [%s]", mergeItem.getMergeType());
}
}
Assert.assertEquals(1, numDelete);
@@ -908,8 +908,8 @@ public class CoveragePackageImportTest {
if (mergeItem.getMergeType() == MergeType.CI_Renamed) {
numRename++;
} else {
- throw new OseeStateException(String.format("Unexpected merge type [%s] for Delete_And_Reorder group",
- mergeItem.getMergeType()));
+ throw new OseeStateException("Unexpected merge type [%s] for Delete_And_Reorder group",
+ mergeItem.getMergeType());
}
}
Assert.assertEquals(2, numRename);
@@ -1058,8 +1058,7 @@ public class CoveragePackageImportTest {
} else if (mergeItem.getMergeType() == MergeType.CI_Delete) {
numDeleted++;
} else {
- throw new OseeStateException(String.format("Unexpected merge type [%s] for CI_Changes group",
- mergeItem.getMergeType()));
+ throw new OseeStateException("Unexpected merge type [%s] for CI_Changes group", mergeItem.getMergeType());
}
}
Assert.assertEquals(2, numRename);
@@ -1181,8 +1180,7 @@ public class CoveragePackageImportTest {
if (mergeItem.getMergeType() == MergeType.CI_Method_Update) {
numUpdateMethod++;
} else {
- throw new OseeStateException(String.format("Unexpected merge type [%s] for CI_Changes group",
- mergeItem.getMergeType()));
+ throw new OseeStateException("Unexpected merge type [%s] for CI_Changes group", mergeItem.getMergeType());
}
}
Assert.assertEquals(2, numUpdateMethod);
diff --git a/plugins/org.eclipse.osee.coverage.test/src/org/eclipse/osee/coverage/test/SampleJavaFileParser.java b/plugins/org.eclipse.osee.coverage.test/src/org/eclipse/osee/coverage/test/SampleJavaFileParser.java
index 7e67e8ac38..6db1faf384 100644
--- a/plugins/org.eclipse.osee.coverage.test/src/org/eclipse/osee/coverage/test/SampleJavaFileParser.java
+++ b/plugins/org.eclipse.osee.coverage.test/src/org/eclipse/osee/coverage/test/SampleJavaFileParser.java
@@ -20,6 +20,7 @@ import org.eclipse.osee.coverage.model.CoverageItem;
import org.eclipse.osee.coverage.model.CoverageOptionManager;
import org.eclipse.osee.coverage.model.CoverageUnit;
import org.eclipse.osee.coverage.model.ICoverageUnitFileContentsProvider;
+import org.eclipse.osee.framework.core.exception.OseeArgumentException;
import org.eclipse.osee.framework.core.exception.OseeCoreException;
import org.eclipse.osee.framework.core.exception.OseeExceptions;
import org.eclipse.osee.framework.core.util.Conditions;
@@ -51,7 +52,7 @@ public class SampleJavaFileParser {
if (m.find()) {
fileCoverageUnit.setNamespace(m.group(1));
} else {
- throw new IllegalArgumentException(String.format("Can't find package for [%s]", url));
+ throw new OseeArgumentException("Can't find package for [%s]", url);
}
fileCoverageUnit.setFileContents(fileStr);
CoverageUnit coverageUnit = null;
diff --git a/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/action/ConfigureCoverageMethodsAction.java b/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/action/ConfigureCoverageMethodsAction.java
index 54d4a62311..f671550220 100644
--- a/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/action/ConfigureCoverageMethodsAction.java
+++ b/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/action/ConfigureCoverageMethodsAction.java
@@ -120,8 +120,8 @@ public class ConfigureCoverageMethodsAction extends Action {
Set<String> names = new HashSet<String>();
for (CoverageOption option : manager.get()) {
if (names.contains(option.getName())) {
- throw new OseeArgumentException(String.format("Multiple options with same name [%s]",
- option.getName()));
+ throw new OseeArgumentException("Multiple options with same name [%s]",
+ option.getName());
} else {
names.add(option.getName());
}
diff --git a/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/editor/CoverageEditorImportTab.java b/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/editor/CoverageEditorImportTab.java
index 42a2675d20..f06e75ba68 100644
--- a/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/editor/CoverageEditorImportTab.java
+++ b/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/editor/CoverageEditorImportTab.java
@@ -120,7 +120,7 @@ public class CoverageEditorImportTab extends FormPage {
public void simulateImport(String importName) throws OseeCoreException {
if (!Strings.isValid(importName)) {
- throw new OseeStateException(String.format("Invalid importName [%s]", importName));
+ throw new OseeStateException("Invalid importName [%s]", importName);
}
AbstractCoverageBlam blam = null;
for (AbstractCoverageBlam abstractCoverageBlam : CoverageManager.getCoverageBlams()) {
@@ -129,7 +129,7 @@ public class CoverageEditorImportTab extends FormPage {
}
}
if (blam == null) {
- throw new OseeArgumentException(String.format("Can't find blam matching name [%s]", importName));
+ throw new OseeArgumentException("Can't find blam matching name [%s]", importName);
}
blam.setCoverageEditor(coverageEditor);
combo.getComboViewer().setSelection(new StructuredSelection(blam), true);
diff --git a/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/merge/MergeItemBase.java b/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/merge/MergeItemBase.java
index 65bb9c4dea..33793a2bbc 100644
--- a/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/merge/MergeItemBase.java
+++ b/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/merge/MergeItemBase.java
@@ -42,7 +42,7 @@ public abstract class MergeItemBase extends NamedIdentity implements IMergeItem
@Override
public void setChecked(boolean checked) throws OseeArgumentException {
if (!isCheckable) {
- throw new OseeArgumentException(String.format("Merge Item is not checkable [%s]", this));
+ throw new OseeArgumentException("Merge Item is not checkable [%s]", this);
}
this.checked = checked;
}
diff --git a/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/model/CoverageImport.java b/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/model/CoverageImport.java
index 1bcd956f19..1e41e63a45 100644
--- a/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/model/CoverageImport.java
+++ b/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/model/CoverageImport.java
@@ -106,7 +106,7 @@ public class CoverageImport extends CoveragePackageBase {
public void addImportRecordFile(File file) throws OseeArgumentException {
if (!file.exists()) {
- throw new OseeArgumentException(String.format("Import Record file [%s] doesn't exist.", file));
+ throw new OseeArgumentException("Import Record file [%s] doesn't exist.", file);
}
importRecordFiles.add(file);
}
diff --git a/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/model/CoverageItem.java b/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/model/CoverageItem.java
index 082c7466b3..7edd631a0d 100644
--- a/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/model/CoverageItem.java
+++ b/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/model/CoverageItem.java
@@ -61,7 +61,7 @@ public class CoverageItem extends NamedIdentity implements ICoverage, IWorkProdu
OseeExceptions.wrapAndThrow(ex);
}
if (!store.getId().equals(PROPERTY_STORE_ID)) {
- throw new OseeArgumentException(String.format("Invalid store id [%s] for CoverageItem", store.getId()));
+ throw new OseeArgumentException("Invalid store id [%s] for CoverageItem", store.getId());
}
CoverageItem item =
diff --git a/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/navigate/CoverageNavigateViewItems.java b/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/navigate/CoverageNavigateViewItems.java
index e1340999a5..9fe25bf448 100644
--- a/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/navigate/CoverageNavigateViewItems.java
+++ b/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/navigate/CoverageNavigateViewItems.java
@@ -23,8 +23,8 @@ import org.eclipse.osee.coverage.action.NewCoveragePackageAction;
import org.eclipse.osee.coverage.action.OpenCoveragePackageAction;
import org.eclipse.osee.coverage.blam.AbstractCoverageBlam;
import org.eclipse.osee.coverage.util.CoverageUtil;
-import org.eclipse.osee.framework.core.exception.OseeArgumentException;
import org.eclipse.osee.framework.core.exception.OseeCoreException;
+import org.eclipse.osee.framework.core.exception.OseeExceptions;
import org.eclipse.osee.framework.jdk.core.util.Strings;
import org.eclipse.osee.framework.logging.OseeLog;
import org.eclipse.osee.framework.plugin.core.util.ExtensionPoints;
@@ -110,8 +110,7 @@ public class CoverageNavigateViewItems extends XNavigateViewItems {
}
data.add((ICoverageNavigateItem) object);
} catch (Exception ex) {
- throw new OseeArgumentException(String.format("Unable to Load: [%s - %s]" + ex.getLocalizedMessage(),
- bundleName, className));
+ OseeExceptions.wrapAndThrow(ex);
}
}
}
diff --git a/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/vcast/CoverageDataFile.java b/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/vcast/CoverageDataFile.java
index 4cad1c0a16..4558108a31 100644
--- a/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/vcast/CoverageDataFile.java
+++ b/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/vcast/CoverageDataFile.java
@@ -37,8 +37,8 @@ public class CoverageDataFile {
this.coverageDataFilename = coverageDataFilename;
File coverageDataFile = getFile();
if (!coverageDataFile.exists()) {
- throw new OseeArgumentException(String.format("VectorCast coverage data file doesn't exist [%s]",
- coverageDataFilename));
+ throw new OseeArgumentException("VectorCast coverage data file doesn't exist [%s]",
+ coverageDataFilename);
}
String fileStr = AFile.readFile(coverageDataFile);
try {
diff --git a/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/vcast/VCastAggregateReport.java b/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/vcast/VCastAggregateReport.java
index 6d6bbc81ec..286d2e54e7 100644
--- a/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/vcast/VCastAggregateReport.java
+++ b/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/vcast/VCastAggregateReport.java
@@ -41,8 +41,8 @@ public class VCastAggregateReport {
public List<AggregateCoverageUnitResult> getResults() throws OseeCoreException {
File reportHtmlFile = getFile();
if (!reportHtmlFile.exists()) {
- throw new OseeArgumentException(String.format(
- "VectorCast vcast_aggregate_coverage_report.html file doesn't exist [%s]", vcastDirectory));
+ throw new OseeArgumentException(
+ "VectorCast vcast_aggregate_coverage_report.html file doesn't exist [%s]", vcastDirectory);
}
List<AggregateCoverageUnitResult> results = new ArrayList<AggregateCoverageUnitResult>();
try {
diff --git a/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/vcast/VCastVcp.java b/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/vcast/VCastVcp.java
index 5b1fac2bcd..837977b84c 100644
--- a/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/vcast/VCastVcp.java
+++ b/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/vcast/VCastVcp.java
@@ -31,7 +31,7 @@ public class VCastVcp {
this.vcastDirectory = vcastDirectory;
File vCastVcpFile = getFile();
if (!vCastVcpFile.exists()) {
- throw new OseeArgumentException(String.format("VectorCast vcast.vcp file doesn't exist [%s]", vcastDirectory));
+ throw new OseeArgumentException("VectorCast vcast.vcp file doesn't exist [%s]", vcastDirectory);
}
VcpSourceFile vcpSourceFile = null;
VcpResultsFile vcpResultsFile = null;
diff --git a/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/vcast/VcpSourceLineFile.java b/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/vcast/VcpSourceLineFile.java
index 187fafde97..ab129ea582 100644
--- a/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/vcast/VcpSourceLineFile.java
+++ b/plugins/org.eclipse.osee.coverage/src/org/eclipse/osee/coverage/vcast/VcpSourceLineFile.java
@@ -37,7 +37,7 @@ public class VcpSourceLineFile {
String lineFilename = vcastDirectory + "/vcast/LINE." + vcpSourceFile.getValue(SourceValue.UNIT_NUMBER);
resultsFile = new File(lineFilename);
if (!resultsFile.exists()) {
- throw new OseeArgumentException(String.format("VectorCast LINE.<num> file doesn't exist [%s]", lineFilename));
+ throw new OseeArgumentException("VectorCast LINE.<num> file doesn't exist [%s]", lineFilename);
}
}
diff --git a/plugins/org.eclipse.osee.define/src/org/eclipse/osee/define/blam/operation/PublishRequirements.java b/plugins/org.eclipse.osee.define/src/org/eclipse/osee/define/blam/operation/PublishRequirements.java
index 24138203a2..8d28d7a05c 100644
--- a/plugins/org.eclipse.osee.define/src/org/eclipse/osee/define/blam/operation/PublishRequirements.java
+++ b/plugins/org.eclipse.osee.define/src/org/eclipse/osee/define/blam/operation/PublishRequirements.java
@@ -109,8 +109,8 @@ public class PublishRequirements extends AbstractBlam {
if (publishAsDiff) {
if (branch == null || date == null && !useBaselineTransaction) {
- throw new OseeCoreException(
- "Must Select a " + branch == null ? "Branch" : "Date" + " to diff against when publishing as Diff");
+ throw new OseeCoreException("Must Select a %s to diff against when publishing as Diff",
+ branch == null ? "Branch" : "Date");
}
}
TransactionDelta txDelta = createTransactionDelta(branch);
diff --git a/plugins/org.eclipse.osee.define/src/org/eclipse/osee/define/relation/Import/RelationImporter.java b/plugins/org.eclipse.osee.define/src/org/eclipse/osee/define/relation/Import/RelationImporter.java
index 63e0d72e5f..0c1c520597 100644
--- a/plugins/org.eclipse.osee.define/src/org/eclipse/osee/define/relation/Import/RelationImporter.java
+++ b/plugins/org.eclipse.osee.define/src/org/eclipse/osee/define/relation/Import/RelationImporter.java
@@ -108,7 +108,7 @@ public class RelationImporter implements RowProcessor {
if (soleArtifact) {
soleArtifact = false;
} else {
- throw new OseeArgumentException("Found more than one match for: " + artifact);
+ throw new OseeArgumentException("Found more than one match for [%s]", artifact);
}
artifactResult = artifact;
}
diff --git a/plugins/org.eclipse.osee.define/src/org/eclipse/osee/define/traceability/ImportTraceabilityOperation.java b/plugins/org.eclipse.osee.define/src/org/eclipse/osee/define/traceability/ImportTraceabilityOperation.java
index 42d2e38350..e9ae4e392b 100644
--- a/plugins/org.eclipse.osee.define/src/org/eclipse/osee/define/traceability/ImportTraceabilityOperation.java
+++ b/plugins/org.eclipse.osee.define/src/org/eclipse/osee/define/traceability/ImportTraceabilityOperation.java
@@ -91,7 +91,7 @@ public class ImportTraceabilityOperation extends AbstractOperation {
} else if (file.isDirectory()) {
handleDirectory(file);
} else {
- throw new OseeStateException(String.format("Invalid path [%s]", file.getCanonicalPath()));
+ throw new OseeStateException("Invalid path [%s]", file.getCanonicalPath());
}
checkForCancelledStatus(monitor);
@@ -110,7 +110,7 @@ public class ImportTraceabilityOperation extends AbstractOperation {
private void handleDirectory(File directory) throws IOException, OseeCoreException {
if (directory == null || directory.getParentFile() == null) {
- throw new OseeArgumentException("The path " + directory + " is invalid.");
+ throw new OseeArgumentException("The path [%s] is invalid.", directory);
}
pathPrefixLength = directory.getParentFile().getAbsolutePath().length();
diff --git a/plugins/org.eclipse.osee.define/src/org/eclipse/osee/define/traceability/blam/RemoveTraceMarksFromTraceUnits.java b/plugins/org.eclipse.osee.define/src/org/eclipse/osee/define/traceability/blam/RemoveTraceMarksFromTraceUnits.java
index aa09342cce..bced0239db 100644
--- a/plugins/org.eclipse.osee.define/src/org/eclipse/osee/define/traceability/blam/RemoveTraceMarksFromTraceUnits.java
+++ b/plugins/org.eclipse.osee.define/src/org/eclipse/osee/define/traceability/blam/RemoveTraceMarksFromTraceUnits.java
@@ -109,11 +109,11 @@ public class RemoveTraceMarksFromTraceUnits extends AbstractBlam {
private void checkPath(String filePath, String type) throws OseeArgumentException {
if (!Strings.isValid(filePath)) {
- throw new OseeArgumentException(String.format("Please enter a valid %s path", type));
+ throw new OseeArgumentException("Please enter a valid %s path", type);
}
File file = new File(filePath);
if (file == null || !file.exists()) {
- throw new OseeArgumentException(String.format("%s path [%s] is not accessible", type, filePath));
+ throw new OseeArgumentException("%s path [%s] is not accessible", type, filePath);
}
}
diff --git a/plugins/org.eclipse.osee.define/src/org/eclipse/osee/define/traceability/operations/TraceUnitFromResourceOperation.java b/plugins/org.eclipse.osee.define/src/org/eclipse/osee/define/traceability/operations/TraceUnitFromResourceOperation.java
index 58ca2da5bc..6bd57e72e4 100644
--- a/plugins/org.eclipse.osee.define/src/org/eclipse/osee/define/traceability/operations/TraceUnitFromResourceOperation.java
+++ b/plugins/org.eclipse.osee.define/src/org/eclipse/osee/define/traceability/operations/TraceUnitFromResourceOperation.java
@@ -88,7 +88,7 @@ public class TraceUnitFromResourceOperation {
Set<String> ids = getTraceUnitHandlerIds();
List<String> notFound = Collections.setComplement(Arrays.asList(traceUnitHandlerIds), ids);
if (!notFound.isEmpty()) {
- throw new OseeArgumentException(String.format("Invalid test unit trace id(s) [%s]", notFound));
+ throw new OseeArgumentException("Invalid test unit trace id(s) [%s]", notFound);
}
} catch (Exception ex) {
OseeExceptions.wrapAndThrow(ex);
@@ -103,10 +103,10 @@ public class TraceUnitFromResourceOperation {
IFileStore fileStore = EFS.getStore(source);
IFileInfo fileInfo = fileStore.fetchInfo();
if (!fileInfo.exists()) {
- throw new OseeArgumentException(String.format("Unable to access source: [%s]", source));
+ throw new OseeArgumentException("Unable to access source: [%s]", source);
}
} catch (CoreException ex) {
- throw new OseeArgumentException(String.format("Unable to access source: [%s]", source));
+ throw new OseeArgumentException("Unable to access source: [%s]", source);
}
}
@@ -115,8 +115,8 @@ public class TraceUnitFromResourceOperation {
throw new OseeArgumentException("Branch to import into was null");
}
if (!importToBranch.getBranchType().isOfType(BranchType.WORKING)) {
- throw new OseeArgumentException(String.format("Branch to import into was not a working branch: [%s]",
- importToBranch));
+ throw new OseeArgumentException("Branch to import into was not a working branch: [%s]",
+ importToBranch);
}
}
}
diff --git a/plugins/org.eclipse.osee.framework.access/src/org/eclipse/osee/framework/access/internal/ObjectAccessProvider.java b/plugins/org.eclipse.osee.framework.access/src/org/eclipse/osee/framework/access/internal/ObjectAccessProvider.java
index de2ff7865f..e90b1bb912 100644
--- a/plugins/org.eclipse.osee.framework.access/src/org/eclipse/osee/framework/access/internal/ObjectAccessProvider.java
+++ b/plugins/org.eclipse.osee.framework.access/src/org/eclipse/osee/framework/access/internal/ObjectAccessProvider.java
@@ -38,7 +38,7 @@ public class ObjectAccessProvider implements IAccessProvider {
} else if (object instanceof Branch) {
setBranchAccessData(userArtifact, (Branch) object, accessData);
} else {
- throw new OseeStateException("Unhandled object type for access control - " + object);
+ throw new OseeStateException("Unhandled object type for access control [%s]", object);
}
}
}
diff --git a/plugins/org.eclipse.osee.framework.access/src/org/eclipse/osee/framework/access/internal/cm/CmAccessControlProviderImpl.java b/plugins/org.eclipse.osee.framework.access/src/org/eclipse/osee/framework/access/internal/cm/CmAccessControlProviderImpl.java
index 84aae3774b..421ad117d0 100644
--- a/plugins/org.eclipse.osee.framework.access/src/org/eclipse/osee/framework/access/internal/cm/CmAccessControlProviderImpl.java
+++ b/plugins/org.eclipse.osee.framework.access/src/org/eclipse/osee/framework/access/internal/cm/CmAccessControlProviderImpl.java
@@ -48,8 +48,8 @@ public class CmAccessControlProviderImpl implements CmAccessControlProvider {
} else if (applicableCms.size() == 1) {
cmToReturn = applicableCms.iterator().next();
} else {
- throw new OseeStateException(String.format(
- "Multiple Configuration Management Systems managing: [%s] cms:%s", object, applicableCms));
+ throw new OseeStateException("Multiple Configuration Management Systems managing: [%s] cms:%s", object,
+ applicableCms);
}
return cmToReturn;
}
diff --git a/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/change/ComputeNetChangeOperation.java b/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/change/ComputeNetChangeOperation.java
index 14858243a0..cd3bf9df77 100644
--- a/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/change/ComputeNetChangeOperation.java
+++ b/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/change/ComputeNetChangeOperation.java
@@ -95,18 +95,17 @@ public class ComputeNetChangeOperation extends AbstractOperation {
// check for case where destination branch is missing an artifact that was modified (not new) on the source branch
if (!change.getDestinationVersion().isValid() && change.getBaselineVersion().isValid()) {
throw new OseeStateException(
- "This should be supported in the future - destination branch is not the source's parent: " + change);
+ "This should be supported in the future - destination branch is not the source's parent [%s]", change);
}
if (change.getDestinationVersion().isValid() && ChangeItemUtil.isDeleted(change.getDestinationVersion())) {
- throw new OseeStateException("Destination was deleted - source should not modify: " + change);
+ throw new OseeStateException("Destination was deleted - source should not modify [%s] ", change);
}
if ((ChangeItemUtil.isIntroduced(change.getCurrentVersion()) || ChangeItemUtil.isNew(change.getCurrentVersion())) //
&& change.getDestinationVersion().isValid()) {
- throw new OseeStateException(
- "Source item marked as new/introduced but destination already has item: " + change);
+ throw new OseeStateException("Source item marked as new/introduced but destination already has item [%s]",
+ change);
}
-
}
-}
+} \ No newline at end of file
diff --git a/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/change/ConflictUtil.java b/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/change/ConflictUtil.java
index f4c36d207b..b6c33f2c08 100644
--- a/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/change/ConflictUtil.java
+++ b/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/change/ConflictUtil.java
@@ -79,7 +79,7 @@ public final class ConflictUtil {
} else if (item instanceof RelationChangeItem) {
type = ConflictType.RELATION;
} else {
- throw new OseeArgumentException(String.format("Unable to convert change item [%s] to conflict type", item));
+ throw new OseeArgumentException("Unable to convert change item [%s] to conflict type", item);
}
return type;
}
diff --git a/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/commit/CommitDbOperation.java b/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/commit/CommitDbOperation.java
index 6d53e7e059..854f60a097 100644
--- a/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/commit/CommitDbOperation.java
+++ b/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/commit/CommitDbOperation.java
@@ -99,7 +99,7 @@ public class CommitDbOperation extends AbstractDbTxOperation {
BranchState storedBranchState;
this.connection = connection;
if (changes.isEmpty()) {
- throw new OseeStateException(" A branch can not be committed without any changes made.");
+ throw new OseeStateException("A branch can not be committed without any changes made.");
}
storedBranchState = sourceBranch.getBranchState();
checkPreconditions();
@@ -126,7 +126,7 @@ public class CommitDbOperation extends AbstractDbTxOperation {
getDatabaseService().runPreparedQueryFetchObject(0, SELECT_SOURCE_BRANCH_STATE, sourceBranch.getId(),
BranchState.COMMIT_IN_PROGRESS.getValue());
if (sourceBranch.getBranchState().equals(BranchState.COMMIT_IN_PROGRESS) || sourceBranch.getArchiveState().isArchived() || count > 0) {
- throw new OseeStateException(String.format("Commit completed or in progress for [%s]", sourceBranch));
+ throw new OseeStateException("Commit completed or in progress for [%s]", sourceBranch);
}
if (!sourceBranch.getBranchState().equals(BranchState.COMMITTED)) {
diff --git a/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/creation/CreateBranchOperation.java b/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/creation/CreateBranchOperation.java
index d8f7f4e71d..cfe63bea49 100644
--- a/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/creation/CreateBranchOperation.java
+++ b/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/creation/CreateBranchOperation.java
@@ -108,8 +108,8 @@ public class CreateBranchOperation extends AbstractDbTxOperation {
if (request.getBranchType().isMergeBranch()) {
if (getDatabaseService().runPreparedQueryFetchObject(0, TEST_MERGE_BRANCH_EXISTENCE, parentBranch.getId(),
destinationBranch.getId()) > 0) {
- throw new OseeStateException(String.format("Existing merge branch detected for [%s] and [%s]",
- parentBranch.getName(), destinationBranch.getName()));
+ throw new OseeStateException("Existing merge branch detected for [%s] and [%s]", parentBranch.getName(),
+ destinationBranch.getName());
}
} else if (!request.getBranchType().isSystemRootBranch()) {
int associatedArtifactId = request.getAssociatedArtifactId();
@@ -120,8 +120,7 @@ public class CreateBranchOperation extends AbstractDbTxOperation {
"select (1) from osee_branch where associated_art_id=? and branch_state <> ?",
request.getAssociatedArtifactId(), BranchState.DELETED.getValue());
if (count > 0) {
- throw new OseeStateException(String.format("Existing branch creation detected for [%s]",
- request.getBranchName()));
+ throw new OseeStateException("Existing branch creation detected for [%s]", request.getBranchName());
}
}
}
diff --git a/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/ExchangeDb.java b/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/ExchangeDb.java
index bb88bfa4ec..e20e890f36 100644
--- a/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/ExchangeDb.java
+++ b/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/ExchangeDb.java
@@ -21,6 +21,7 @@ import org.eclipse.osee.framework.branch.management.exchange.export.DbTableExpor
import org.eclipse.osee.framework.branch.management.exchange.export.ManifestExportItem;
import org.eclipse.osee.framework.branch.management.exchange.export.MetadataExportItem;
import org.eclipse.osee.framework.branch.management.exchange.handler.ExportItem;
+import org.eclipse.osee.framework.core.exception.OseeArgumentException;
import org.eclipse.osee.framework.database.IOseeDatabaseService;
import org.eclipse.osee.framework.database.core.IOseeSequence;
import org.eclipse.osee.framework.jdk.core.type.Pair;
@@ -205,7 +206,7 @@ public class ExchangeDb {
}
}
if (minTxs > maxTxs) {
- throw new Exception(String.format("Invalid transaction range: min - %d > max - %d", minTxs, maxTxs));
+ throw new OseeArgumentException("Invalid transaction range: min - %d > max - %d", minTxs, maxTxs);
}
return new Pair<String, Object[]>(String.format(originalQuery, optionString),
diff --git a/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/ImportController.java b/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/ImportController.java
index 618ae0ffa3..344cd76686 100644
--- a/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/ImportController.java
+++ b/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/ImportController.java
@@ -199,7 +199,7 @@ public final class ImportController {
private MetaData checkMetadata(IExportItem importFile) throws OseeArgumentException {
MetaData metadata = metadataHandler.getMetadata(importFile.getSource());
if (metadata == null) {
- throw new OseeArgumentException(String.format("Invalid metadata for [%s]", importFile.getSource()));
+ throw new OseeArgumentException("Invalid metadata for [%s]", importFile.getSource());
}
return metadata;
}
diff --git a/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/handler/BranchDataSaxHandler.java b/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/handler/BranchDataSaxHandler.java
index c3e21f689a..23e2fc3361 100644
--- a/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/handler/BranchDataSaxHandler.java
+++ b/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/handler/BranchDataSaxHandler.java
@@ -103,9 +103,9 @@ public class BranchDataSaxHandler extends BaseDbSaxHandler {
private void checkSelectedBranches(int... branchesToImport) throws OseeDataStoreException {
if (branchesToImport != null && branchesToImport.length > 0) {
if (!areAvailable(branchesToImport)) {
- throw new OseeDataStoreException(String.format(
+ throw new OseeDataStoreException(
"Branches not found in import file:\n\t\t- selected to import: [%s]\n\t\t- in import file: [%s]",
- branchesToImport, getAllBranchDataFromImportFile()));
+ branchesToImport, getAllBranchDataFromImportFile());
}
}
}
diff --git a/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/handler/DataToSql.java b/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/handler/DataToSql.java
index 9dfc758af9..056e47527b 100644
--- a/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/handler/DataToSql.java
+++ b/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/handler/DataToSql.java
@@ -80,9 +80,9 @@ public class DataToSql {
Method mainMethod = clazz.getMethod("valueOf", new Class[] {Object.class});
convertedObject = mainMethod.invoke(null, value);
} catch (Exception ex1) {
- throw new OseeArgumentException(String.format(
+ throw new OseeArgumentException(
"Unable to convert from string to object for - attribute [%s] to class [%s]", columnName,
- clazz.getName()));
+ clazz.getName());
}
}
} else {
diff --git a/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/handler/DbTableSaxHandler.java b/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/handler/DbTableSaxHandler.java
index fb3c12ee51..c250e04c70 100644
--- a/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/handler/DbTableSaxHandler.java
+++ b/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/handler/DbTableSaxHandler.java
@@ -85,8 +85,7 @@ public class DbTableSaxHandler extends BaseDbSaxHandler {
transferredBinaryContent.add(locator);
return locator.getLocation().toASCIIString();
} else {
- throw new OseeStateException(String.format(
- "Unable to locate resource in zip file - ZipEntry was null for [%s]", uriValue));
+ throw new OseeStateException("Unable to locate resource in zip file - ZipEntry was null for [%s]", uriValue);
}
} else {
throw new OseeStateException("Uncompressed folder was Null.");
diff --git a/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/resource/ExchangeLocatorProvider.java b/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/resource/ExchangeLocatorProvider.java
index b7e9b6252f..4d9ec1b818 100644
--- a/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/resource/ExchangeLocatorProvider.java
+++ b/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/resource/ExchangeLocatorProvider.java
@@ -45,7 +45,7 @@ public class ExchangeLocatorProvider implements IResourceLocatorProvider {
throw new MalformedLocatorException(ex);
}
} else {
- throw new MalformedLocatorException(String.format("Invalid path hint: [%s]", path));
+ throw new MalformedLocatorException("Invalid path hint: [%s]", path);
}
return new ResourceLocator(uri);
}
diff --git a/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/resource/ExchangeProvider.java b/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/resource/ExchangeProvider.java
index 5ef072fb71..74dbc2b3b4 100644
--- a/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/resource/ExchangeProvider.java
+++ b/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/resource/ExchangeProvider.java
@@ -120,7 +120,7 @@ public class ExchangeProvider implements IResourceProvider {
Lib.close(inputStream);
}
if (toReturn == null) {
- throw new OseeStateException(String.format("We failed to save resource %s.", locator.getLocation()));
+ throw new OseeStateException("We failed to save resource %s.", locator.getLocation());
}
return toReturn;
}
diff --git a/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/transform/ExchangeDataProcessor.java b/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/transform/ExchangeDataProcessor.java
index c934f4dac0..ae67acf5df 100644
--- a/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/transform/ExchangeDataProcessor.java
+++ b/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/transform/ExchangeDataProcessor.java
@@ -91,7 +91,7 @@ public final class ExchangeDataProcessor {
private void renameExportItem(File original, File destination) throws OseeCoreException {
boolean wasSuccessful = original.renameTo(destination);
if (!wasSuccessful) {
- throw new OseeStateException(String.format("Error renaming [%s] to [%s]", original, destination));
+ throw new OseeStateException("Error renaming [%s] to [%s]", original, destination);
}
}
diff --git a/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/transform/V0_9_2Transformer.java b/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/transform/V0_9_2Transformer.java
index e97106d196..f060b24396 100644
--- a/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/transform/V0_9_2Transformer.java
+++ b/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/exchange/transform/V0_9_2Transformer.java
@@ -175,7 +175,7 @@ public class V0_9_2Transformer implements IOseeExchangeVersionTransformer {
private ModificationType[] getNextPossibleStates(ModificationType state) throws OseeStateException {
ModificationType[] nextAllowed = allowedStates.get(state);
if (nextAllowed == null) {
- throw new OseeStateException(String.format("Unexcepted modification type [%s]", state.toString()));
+ throw new OseeStateException("Unexcepted modification type [%s]", state.toString());
}
return nextAllowed;
}
diff --git a/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/purge/PurgeBranchOperation.java b/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/purge/PurgeBranchOperation.java
index d4c04138d2..45bd443f62 100644
--- a/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/purge/PurgeBranchOperation.java
+++ b/plugins/org.eclipse.osee.framework.branch.management/src/org/eclipse/osee/framework/branch/management/purge/PurgeBranchOperation.java
@@ -80,8 +80,8 @@ public class PurgeBranchOperation extends AbstractDbTxOperation {
oseeDatabaseProvider.getOseeDatabaseService().runPreparedQueryFetchObject(0, COUNT_CHILD_BRANCHES,
branch.getId());
if (numberOfChildren > 0) {
- throw new OseeArgumentException(String.format("Unable to purge a branch containing children: branchId[%s]",
- branch.getId()));
+ throw new OseeArgumentException("Unable to purge a branch containing children: branchId[%s]",
+ branch.getId());
}
boolean isAddressingArchived =
diff --git a/plugins/org.eclipse.osee.framework.core.client/src/org/eclipse/osee/framework/core/client/ClientSessionManager.java b/plugins/org.eclipse.osee.framework.core.client/src/org/eclipse/osee/framework/core/client/ClientSessionManager.java
index 48edc6a53c..80078f11fd 100644
--- a/plugins/org.eclipse.osee.framework.core.client/src/org/eclipse/osee/framework/core/client/ClientSessionManager.java
+++ b/plugins/org.eclipse.osee.framework.core.client/src/org/eclipse/osee/framework/core/client/ClientSessionManager.java
@@ -93,7 +93,7 @@ public class ClientSessionManager {
if (sql != null) {
return sql;
}
- throw new OseeArgumentException(String.format("Invalid sql key [%s]", sqlEnum.toString()));
+ throw new OseeArgumentException("Invalid sql key [%s]", sqlEnum.toString());
}
public static List<String> getAuthenticationProtocols() {
diff --git a/plugins/org.eclipse.osee.framework.core.client/src/org/eclipse/osee/framework/core/client/server/HttpRequest.java b/plugins/org.eclipse.osee.framework.core.client/src/org/eclipse/osee/framework/core/client/server/HttpRequest.java
index d86602a34d..b3bf651dbd 100644
--- a/plugins/org.eclipse.osee.framework.core.client/src/org/eclipse/osee/framework/core/client/server/HttpRequest.java
+++ b/plugins/org.eclipse.osee.framework.core.client/src/org/eclipse/osee/framework/core/client/server/HttpRequest.java
@@ -187,7 +187,7 @@ public class HttpRequest {
urlRequest = matcher.group(1);
if (!Strings.isValid(urlRequest)) {
- throw new OseeArgumentException("Unknown requestType \"" + rawRequest + "\"");
+ throw new OseeArgumentException("Unknown requestType [%s]", rawRequest);
}
String data = matcher.group(2);
Matcher dataMatcher = Pattern.compile("([^&]*?)=([^&]*)").matcher(data);
@@ -223,7 +223,7 @@ public class HttpRequest {
parameterMap.put("guid", guid);
urlRequest = "Define";
} else {
- throw new OseeArgumentException("Unnable to parse old style link: \"" + rawRequest + "\"");
+ throw new OseeArgumentException("Unnable to parse old style link [%s]", rawRequest);
}
}
}
diff --git a/plugins/org.eclipse.osee.framework.core.datastore/src/org/eclipse/osee/framework/core/datastore/cache/DatabaseArtifactTypeAccessor.java b/plugins/org.eclipse.osee.framework.core.datastore/src/org/eclipse/osee/framework/core/datastore/cache/DatabaseArtifactTypeAccessor.java
index a62ff79c5d..53e2ac3f5b 100644
--- a/plugins/org.eclipse.osee.framework.core.datastore/src/org/eclipse/osee/framework/core/datastore/cache/DatabaseArtifactTypeAccessor.java
+++ b/plugins/org.eclipse.osee.framework.core.datastore/src/org/eclipse/osee/framework/core/datastore/cache/DatabaseArtifactTypeAccessor.java
@@ -135,12 +135,12 @@ public class DatabaseArtifactTypeAccessor extends AbstractDatabaseAccessor<Artif
ArtifactType superArtType = cache.getById(superArtTypeId);
if (baseArtType == null) {
- throw new OseeInvalidInheritanceException(String.format(
- "ArtifactType [%s] which inherits from [%s] is null", artTypeId, superArtType));
+ throw new OseeInvalidInheritanceException("ArtifactType [%s] which inherits from [%s] is null",
+ artTypeId, superArtType);
}
if (superArtType == null) {
- throw new OseeInvalidInheritanceException(String.format(
- "ArtifactType [%s] which inherits from null artifact [%s]", artTypeId, superArtType));
+ throw new OseeInvalidInheritanceException("ArtifactType [%s] which inherits from null artifact [%s]",
+ artTypeId, superArtType);
}
baseToSuperTypes.put(baseArtType, superArtType);
}
diff --git a/plugins/org.eclipse.osee.framework.core.datastore/src/org/eclipse/osee/framework/core/datastore/cache/DatabaseBranchAccessor.java b/plugins/org.eclipse.osee.framework.core.datastore/src/org/eclipse/osee/framework/core/datastore/cache/DatabaseBranchAccessor.java
index 46459432b7..bf74fa70cb 100644
--- a/plugins/org.eclipse.osee.framework.core.datastore/src/org/eclipse/osee/framework/core/datastore/cache/DatabaseBranchAccessor.java
+++ b/plugins/org.eclipse.osee.framework.core.datastore/src/org/eclipse/osee/framework/core/datastore/cache/DatabaseBranchAccessor.java
@@ -147,8 +147,8 @@ public class DatabaseBranchAccessor extends AbstractDatabaseAccessor<Branch> {
Branch childBranch = entry.getKey();
Branch parentBranch = branchCache.getById(entry.getValue());
if (parentBranch == null) {
- throw new BranchDoesNotExist(String.format("Parent Branch id:[%s] does not exist for child branch [%s]",
- entry.getValue(), entry.getKey()));
+ throw new BranchDoesNotExist("Parent Branch id:[%s] does not exist for child branch [%s]",
+ entry.getValue(), entry.getKey());
}
childBranch.setParentBranch(parentBranch);
}
diff --git a/plugins/org.eclipse.osee.framework.core.datastore/src/org/eclipse/osee/framework/core/datastore/cache/DatabaseTransactionRecordAccessor.java b/plugins/org.eclipse.osee.framework.core.datastore/src/org/eclipse/osee/framework/core/datastore/cache/DatabaseTransactionRecordAccessor.java
index e3746b23c1..f391eb44dd 100644
--- a/plugins/org.eclipse.osee.framework.core.datastore/src/org/eclipse/osee/framework/core/datastore/cache/DatabaseTransactionRecordAccessor.java
+++ b/plugins/org.eclipse.osee.framework.core.datastore/src/org/eclipse/osee/framework/core/datastore/cache/DatabaseTransactionRecordAccessor.java
@@ -99,7 +99,7 @@ public class DatabaseTransactionRecordAccessor implements ITransactionDataAccess
toReturn = loadFirstTransactionRecord(cache, branch, SELECT_BRANCH_TRANSACTIONS, branch.getId());
break;
default:
- throw new OseeStateException(String.format("Transaction Type [%s] is not supported", transactionType));
+ throw new OseeStateException("Transaction Type [%s] is not supported", transactionType);
}
return toReturn;
}
diff --git a/plugins/org.eclipse.osee.framework.core.datastore/src/org/eclipse/osee/framework/core/datastore/schema/sql/SqlManager.java b/plugins/org.eclipse.osee.framework.core.datastore/src/org/eclipse/osee/framework/core/datastore/schema/sql/SqlManager.java
index 9d7e5c75e3..1340f0cd57 100644
--- a/plugins/org.eclipse.osee.framework.core.datastore/src/org/eclipse/osee/framework/core/datastore/schema/sql/SqlManager.java
+++ b/plugins/org.eclipse.osee.framework.core.datastore/src/org/eclipse/osee/framework/core/datastore/schema/sql/SqlManager.java
@@ -130,7 +130,7 @@ public abstract class SqlManager {
case BOOLEAN:
return !Strings.isValid(value) ? false : Boolean.parseBoolean(value);
default:
- throw new OseeDataStoreException("unexpected column type: " + columnType);
+ throw new OseeDataStoreException("unexpected column type [%s]", columnType);
}
}
diff --git a/plugins/org.eclipse.osee.framework.core.dsl.ui.integration/src/org/eclipse/osee/framework/core/dsl/ui/integration/operations/ExcelToEMFModel.java b/plugins/org.eclipse.osee.framework.core.dsl.ui.integration/src/org/eclipse/osee/framework/core/dsl/ui/integration/operations/ExcelToEMFModel.java
index f9b6f8f238..ecb1c3aebf 100644
--- a/plugins/org.eclipse.osee.framework.core.dsl.ui.integration/src/org/eclipse/osee/framework/core/dsl/ui/integration/operations/ExcelToEMFModel.java
+++ b/plugins/org.eclipse.osee.framework.core.dsl.ui.integration/src/org/eclipse/osee/framework/core/dsl/ui/integration/operations/ExcelToEMFModel.java
@@ -84,7 +84,7 @@ public class ExcelToEMFModel implements IOseeDataTypeProcessor {
} else if (classToLookFor.equals(XOseeEnumType.class)) {
types = getCurrentModel().getEnumTypes();
} else {
- throw new OseeArgumentException(classToLookFor.getName() + " not a supported type");
+ throw new OseeArgumentException("[%s] not a supported type", classToLookFor.getName());
}
for (OseeType oseeTypes : types) {
if (name.equals(oseeTypes.getName())) {
@@ -98,7 +98,7 @@ public class ExcelToEMFModel implements IOseeDataTypeProcessor {
public void onArtifactTypeInheritance(String ancestor, Collection<String> descendants) throws OseeCoreException {
XArtifactType ancestorType = (XArtifactType) getObject(ancestor, XArtifactType.class);
if (ancestorType == null) {
- throw new OseeInvalidInheritanceException("Ancestor [%s]");
+ throw new OseeInvalidInheritanceException("Ancestor [%s]", ancestor);
}
// if (superArtifactTypeName != null) {
@@ -180,7 +180,7 @@ public class ExcelToEMFModel implements IOseeDataTypeProcessor {
}
if (superArtifactType == null || attributeType == null) {
- throw new OseeStateException(String.format("Type Missing: %s - %s", artifactSuperTypeName, attributeName));
+ throw new OseeStateException("Type Missing: %s - %s", artifactSuperTypeName, attributeName);
}
XAttributeTypeRef reference = factory.createXAttributeTypeRef();
reference.setValidAttributeType(attributeType);
@@ -325,11 +325,11 @@ public class ExcelToEMFModel implements IOseeDataTypeProcessor {
private static void checkEntryIntegrity(String enumTypeName, List<Pair<String, Integer>> entries) throws OseeCoreException {
if (entries == null) {
- throw new OseeArgumentException(String.format("Osee Enum Type [%s] had null entries", enumTypeName));
+ throw new OseeArgumentException("Osee Enum Type [%s] had null entries", enumTypeName);
}
- // if (entries.size() <= 0) throw new OseeArgumentException(String.format("Osee Enum Type [%s] had 0 entries",
- // enumTypeName));
+ // if (entries.size() <= 0) throw new OseeArgumentException("Osee Enum Type [%s] had 0 entries",
+ // enumTypeName);
Map<String, Integer> values = new HashMap<String, Integer>();
for (Pair<String, Integer> entry : entries) {
String name = entry.getFirst();
@@ -341,12 +341,10 @@ public class ExcelToEMFModel implements IOseeDataTypeProcessor {
throw new OseeArgumentException("Enum entry ordinal cannot be of negative value");
}
if (values.containsKey(name)) {
- throw new OseeArgumentException(String.format("Unique enum entry name violation - [%s] already exists.",
- name));
+ throw new OseeArgumentException("Unique enum entry name violation - [%s] already exists.", name);
}
if (values.containsValue(ordinal)) {
- throw new OseeArgumentException(String.format("Unique enum entry ordinal violation - [%s] already exists.",
- ordinal));
+ throw new OseeArgumentException("Unique enum entry ordinal violation - [%s] already exists.", ordinal);
}
values.put(name, ordinal);
}
diff --git a/plugins/org.eclipse.osee.framework.core.message/src/org/eclipse/osee/framework/core/message/ChangeItemUtil.java b/plugins/org.eclipse.osee.framework.core.message/src/org/eclipse/osee/framework/core/message/ChangeItemUtil.java
index 78df8e189d..2ff6a1ea8e 100644
--- a/plugins/org.eclipse.osee.framework.core.message/src/org/eclipse/osee/framework/core/message/ChangeItemUtil.java
+++ b/plugins/org.eclipse.osee.framework.core.message/src/org/eclipse/osee/framework/core/message/ChangeItemUtil.java
@@ -35,8 +35,7 @@ public final class ChangeItemUtil {
if (!toReturn.isValid()) {
toReturn = item.getCurrentVersion();
if (!toReturn.isValid()) {
- throw new OseeStateException(String.format("Cannot find a valid starting point for change item: %s",
- item));
+ throw new OseeStateException("Cannot find a valid starting point for change item: %s", item);
}
}
}
diff --git a/plugins/org.eclipse.osee.framework.core.message/src/org/eclipse/osee/framework/core/message/internal/DataTranslationService.java b/plugins/org.eclipse.osee.framework.core.message/src/org/eclipse/osee/framework/core/message/internal/DataTranslationService.java
index 826feda3f8..5f86b15159 100644
--- a/plugins/org.eclipse.osee.framework.core.message/src/org/eclipse/osee/framework/core/message/internal/DataTranslationService.java
+++ b/plugins/org.eclipse.osee.framework.core.message/src/org/eclipse/osee/framework/core/message/internal/DataTranslationService.java
@@ -68,7 +68,7 @@ public class DataTranslationService implements IDataTranslationService {
Conditions.checkNotNull(txId, "translator Id");
ITranslator<?> toReturn = translators.get(txId);
if (toReturn == null) {
- throw new OseeStateException(String.format("Unable to find a match for translator id [%s]", txId));
+ throw new OseeStateException("Unable to find a match for translator id [%s]", txId);
}
return toReturn;
diff --git a/plugins/org.eclipse.osee.framework.core.model/src/org/eclipse/osee/framework/core/model/OseeCachingService.java b/plugins/org.eclipse.osee.framework.core.model/src/org/eclipse/osee/framework/core/model/OseeCachingService.java
index 0afccf724d..ca75f1a5fe 100644
--- a/plugins/org.eclipse.osee.framework.core.model/src/org/eclipse/osee/framework/core/model/OseeCachingService.java
+++ b/plugins/org.eclipse.osee.framework.core.model/src/org/eclipse/osee/framework/core/model/OseeCachingService.java
@@ -98,7 +98,7 @@ public class OseeCachingService implements IOseeCachingService {
return cache;
}
}
- throw new OseeArgumentException(String.format("Unable to find cache for id [%s]", cacheId));
+ throw new OseeArgumentException("Unable to find cache for id [%s]", cacheId);
}
@Override
diff --git a/plugins/org.eclipse.osee.framework.core.model/src/org/eclipse/osee/framework/core/model/cache/AbstractOseeCache.java b/plugins/org.eclipse.osee.framework.core.model/src/org/eclipse/osee/framework/core/model/cache/AbstractOseeCache.java
index 3192ff7abf..8a4a30a875 100644
--- a/plugins/org.eclipse.osee.framework.core.model/src/org/eclipse/osee/framework/core/model/cache/AbstractOseeCache.java
+++ b/plugins/org.eclipse.osee.framework.core.model/src/org/eclipse/osee/framework/core/model/cache/AbstractOseeCache.java
@@ -166,8 +166,8 @@ public abstract class AbstractOseeCache<T extends AbstractOseeType> implements I
// }
// }
if (cachedTypes.size() > 1) {
- throw new OseeStateException(String.format("Item [%s:%s] does not have a unique name. Matching types - ",
- type.getName(), type.getGuid(), itemsFound));
+ throw new OseeStateException("Item [%s:%s] does not have a unique name. Matching types - ", type.getName(),
+ type.getGuid(), itemsFound);
}
}
@@ -195,7 +195,7 @@ public abstract class AbstractOseeCache<T extends AbstractOseeType> implements I
ensurePopulated();
Collection<T> values = getByName(typeName);
if (values.size() > 1) {
- throw new OseeStateException(String.format("Multiple items matching [%s] name exist", typeName));
+ throw new OseeStateException("Multiple items matching [%s] name exist", typeName);
}
return values.isEmpty() ? null : values.iterator().next();
}
@@ -214,8 +214,8 @@ public abstract class AbstractOseeCache<T extends AbstractOseeType> implements I
ensurePopulated();
Collection<T> types = getByName(typeName);
if (types.size() != 1) {
- throw new OseeArgumentException(
- "AbstractOseeCache expected 1 type but found " + types.size() + " types for " + typeName);
+ throw new OseeArgumentException("AbstractOseeCache expected 1 type but found [%d] types for [%s]",
+ types.size(), typeName);
}
return types.iterator().next();
}
@@ -223,7 +223,7 @@ public abstract class AbstractOseeCache<T extends AbstractOseeType> implements I
public T getByGuid(String guid) throws OseeCoreException {
ensurePopulated();
if (!GUID.isValid(guid)) {
- throw new OseeArgumentException(String.format("[%s] is not a valid guid", guid));
+ throw new OseeArgumentException("[%s] is not a valid guid", guid);
}
return guidToTypeMap.get(guid);
}
diff --git a/plugins/org.eclipse.osee.framework.core.model/src/org/eclipse/osee/framework/core/model/cache/TransactionCache.java b/plugins/org.eclipse.osee.framework.core.model/src/org/eclipse/osee/framework/core/model/cache/TransactionCache.java
index cb50ae5702..92a69e8fcf 100644
--- a/plugins/org.eclipse.osee.framework.core.model/src/org/eclipse/osee/framework/core/model/cache/TransactionCache.java
+++ b/plugins/org.eclipse.osee.framework.core.model/src/org/eclipse/osee/framework/core/model/cache/TransactionCache.java
@@ -99,7 +99,7 @@ public class TransactionCache implements IOseeCache<TransactionRecord> {
if (txId == 1) { // handle bootstrap case for system root branch creation
return null;
}
- throw new OseeStateException(String.format("Transaction Record[%s] was not found", txId));
+ throw new OseeStateException("Transaction Record[%s] was not found", txId);
}
}
return transactionRecord;
diff --git a/plugins/org.eclipse.osee.framework.core.model/src/org/eclipse/osee/framework/core/model/internal/fields/ArtifactSuperTypeField.java b/plugins/org.eclipse.osee.framework.core.model/src/org/eclipse/osee/framework/core/model/internal/fields/ArtifactSuperTypeField.java
index 4fd461221d..ff5cdc5ebd 100644
--- a/plugins/org.eclipse.osee.framework.core.model/src/org/eclipse/osee/framework/core/model/internal/fields/ArtifactSuperTypeField.java
+++ b/plugins/org.eclipse.osee.framework.core.model/src/org/eclipse/osee/framework/core/model/internal/fields/ArtifactSuperTypeField.java
@@ -34,13 +34,12 @@ public final class ArtifactSuperTypeField extends CollectionField<ArtifactType>
Collection<ArtifactType> toReturn = Collections.emptyList();
if (input == null || input.isEmpty()) {
if (!baseType.equals(CoreArtifactTypes.Artifact)) {
- throw new OseeInvalidInheritanceException(String.format(
- "All artifacts must inherit from [Artifact] - attempted make [%s] have null inheritance", baseType));
+ throw new OseeInvalidInheritanceException(
+ "All artifacts must inherit from [Artifact] - attempted make [%s] have null inheritance", baseType);
}
} else {
if (input.contains(baseType)) {
- throw new OseeInvalidInheritanceException(String.format(
- "Circular inheritance detected for artifact type [%s]", baseType));
+ throw new OseeInvalidInheritanceException("Circular inheritance detected for artifact type [%s]", baseType);
}
toReturn = input;
}
diff --git a/plugins/org.eclipse.osee.framework.core.model/src/org/eclipse/osee/framework/core/model/type/OseeEnumType.java b/plugins/org.eclipse.osee.framework.core.model/src/org/eclipse/osee/framework/core/model/type/OseeEnumType.java
index 9b9ceb0b90..3c01007f4d 100644
--- a/plugins/org.eclipse.osee.framework.core.model/src/org/eclipse/osee/framework/core/model/type/OseeEnumType.java
+++ b/plugins/org.eclipse.osee.framework.core.model/src/org/eclipse/osee/framework/core/model/type/OseeEnumType.java
@@ -86,7 +86,7 @@ public class OseeEnumType extends AbstractOseeType implements Comparable<OseeEnu
}
}
if (toReturn == null) {
- throw new OseeArgumentException(String.format("No enum const [%s] - ordinal [%s]", getName(), ordinal));
+ throw new OseeArgumentException("No enum const [%s] - ordinal [%s]", getName(), ordinal);
}
return toReturn;
}
@@ -102,7 +102,7 @@ public class OseeEnumType extends AbstractOseeType implements Comparable<OseeEnu
}
}
if (toReturn == null) {
- throw new OseeArgumentException(String.format("No enum const [%s].[%s]", getName(), entryName));
+ throw new OseeArgumentException("No enum const [%s].[%s]", getName(), entryName);
}
return toReturn;
}
@@ -122,8 +122,8 @@ public class OseeEnumType extends AbstractOseeType implements Comparable<OseeEnu
List<OseeEnumEntry> entries = new ArrayList<OseeEnumEntry>();
entries.addAll(Arrays.asList(values()));
if (!entries.remove(entry)) {
- throw new OseeArgumentException(String.format("OseeEnumEntry[%s] does not exist on OseeEnumType[%s]", entry,
- this));
+ throw new OseeArgumentException("OseeEnumEntry[%s] does not exist on OseeEnumType[%s]", entry,
+ this);
}
setEntries(entries);
}
diff --git a/plugins/org.eclipse.osee.framework.core.server/src/org/eclipse/osee/framework/core/server/internal/AuthenticationManager.java b/plugins/org.eclipse.osee.framework.core.server/src/org/eclipse/osee/framework/core/server/internal/AuthenticationManager.java
index fa1eea48c4..3d5fa86625 100644
--- a/plugins/org.eclipse.osee.framework.core.server/src/org/eclipse/osee/framework/core/server/internal/AuthenticationManager.java
+++ b/plugins/org.eclipse.osee.framework.core.server/src/org/eclipse/osee/framework/core/server/internal/AuthenticationManager.java
@@ -52,8 +52,7 @@ public class AuthenticationManager implements IAuthenticationManager {
return provider.authenticate(credential);
}
}
- throw new OseeAuthenticationException(String.format("Invalid protocol [%s]",
- credential.getAuthenticationProtocol()));
+ throw new OseeAuthenticationException("Invalid protocol [%s]", credential.getAuthenticationProtocol());
}
@Override
@@ -81,8 +80,7 @@ public class AuthenticationManager implements IAuthenticationManager {
return provider.asOseeUserId(credential);
}
}
- throw new OseeAuthenticationException(String.format("Invalid protocol [%s]",
- credential.getAuthenticationProtocol()));
+ throw new OseeAuthenticationException("Invalid protocol [%s]", credential.getAuthenticationProtocol());
}
private boolean isGuestLogin(OseeCredential credential) {
diff --git a/plugins/org.eclipse.osee.framework.core.server/src/org/eclipse/osee/framework/core/server/internal/InternalOseeServerInfo.java b/plugins/org.eclipse.osee.framework.core.server/src/org/eclipse/osee/framework/core/server/internal/InternalOseeServerInfo.java
index 1a4d9f67ed..2219884b42 100644
--- a/plugins/org.eclipse.osee.framework.core.server/src/org/eclipse/osee/framework/core/server/internal/InternalOseeServerInfo.java
+++ b/plugins/org.eclipse.osee.framework.core.server/src/org/eclipse/osee/framework/core/server/internal/InternalOseeServerInfo.java
@@ -53,7 +53,7 @@ class InternalOseeServerInfo extends OseeServerInfo {
private void checkVersionArgument(String version) throws OseeCoreException {
if (!Strings.isValid(version)) {
- throw new OseeArgumentException(String.format("Osee version argument is invalid"));
+ throw new OseeArgumentException("Osee version argument is invalid");
}
}
@@ -94,7 +94,7 @@ class InternalOseeServerInfo extends OseeServerInfo {
synchronized (updateFromStore) {
checkVersionArgument(version);
if (defaultVersions.contains(version)) {
- throw new OseeArgumentException(String.format("Unable to remove default Osee version [%s]", version));
+ throw new OseeArgumentException("Unable to remove default Osee version [%s]", version);
}
Set<String> supportedVersions = new HashSet<String>(Arrays.asList(getVersion()));
if (supportedVersions.contains(version)) {
@@ -106,7 +106,7 @@ class InternalOseeServerInfo extends OseeServerInfo {
isRegistered = ApplicationServerDataStore.registerWithDb(this);
updateFromStore.setValue(true);
} else {
- throw new OseeStateException(String.format("Not part of the supported version [%s]", version));
+ throw new OseeStateException("Not part of the supported version [%s]", version);
}
}
}
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/BranchType.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/BranchType.java
index a9ea059796..3c470d406b 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/BranchType.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/BranchType.java
@@ -61,6 +61,6 @@ public enum BranchType {
return type;
}
}
- throw new OseeArgumentException("No branch type with value " + value);
+ throw new OseeArgumentException("No branch type with value [%s]", value);
}
}
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/CacheOperation.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/CacheOperation.java
index 78e88e032b..af2d90fe98 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/CacheOperation.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/CacheOperation.java
@@ -29,6 +29,6 @@ public enum CacheOperation {
return op;
}
}
- throw new OseeArgumentException(String.format("Unable to find cache operation matching [%s]", value));
+ throw new OseeArgumentException("Unable to find cache operation matching [%s]", value);
}
}
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/ConflictStatus.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/ConflictStatus.java
index 481b357e26..c3ba4d2327 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/ConflictStatus.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/ConflictStatus.java
@@ -46,7 +46,7 @@ public enum ConflictStatus {
return type;
}
}
- throw new OseeArgumentException(String.format("[%s] is not a valid ConflictStatus"));
+ throw new OseeArgumentException("[%s] is not a valid ConflictStatus");
}
public boolean isConflict() {
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/ConflictType.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/ConflictType.java
index e79a40fd0a..917cdb65eb 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/ConflictType.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/ConflictType.java
@@ -37,6 +37,6 @@ public enum ConflictType {
return type;
}
}
- throw new OseeArgumentException(String.format("[%s] is not a valid ConflictType"));
+ throw new OseeArgumentException("[%s] is not a valid ConflictType");
}
}
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/Function.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/Function.java
index 5451915621..671952a541 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/Function.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/Function.java
@@ -31,6 +31,6 @@ public enum Function {
return function;
}
}
- throw new OseeCoreException(String.format("Invalid name - Function [%s] was not found ", toMatch));
+ throw new OseeCoreException("Invalid name - Function [%s] was not found ", toMatch);
}
}
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/ModificationType.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/ModificationType.java
index 586a170f60..1a0d970a87 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/ModificationType.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/ModificationType.java
@@ -93,7 +93,7 @@ public enum ModificationType {
return modtype;
}
}
- throw new OseeArgumentException(value + " does not correspond to any defined ModificationType enumerations");
+ throw new OseeArgumentException("[%s] does not correspond to any defined ModificationType enumerations", value);
}
public boolean isDeleted() {
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/StorageState.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/StorageState.java
index 025bbc49d6..467079dc85 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/StorageState.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/StorageState.java
@@ -39,6 +39,6 @@ public enum StorageState {
return type;
}
}
- throw new OseeArgumentException(String.format("[%s] is not a valid StorageState"));
+ throw new OseeArgumentException("[%s] is not a valid StorageState");
}
}
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/TxChange.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/TxChange.java
index 85f895505a..82460f8bf2 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/TxChange.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/enums/TxChange.java
@@ -46,7 +46,7 @@ public enum TxChange {
return change;
}
}
- throw new OseeArgumentException(value + " does not correspond to any defined ModificationType enumerations");
+ throw new OseeArgumentException("[%s] does not correspond to any defined ModificationType enumerations", value);
}
public static TxChange getCurrent(ModificationType type) {
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/ArtifactDoesNotExist.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/ArtifactDoesNotExist.java
index 630e4bc5a8..35b43a3904 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/ArtifactDoesNotExist.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/ArtifactDoesNotExist.java
@@ -17,7 +17,7 @@ public class ArtifactDoesNotExist extends OseeCoreException {
private static final long serialVersionUID = 1L;
- public ArtifactDoesNotExist(String message) {
- super(message);
+ public ArtifactDoesNotExist(String message, Object... args) {
+ super(message, args);
}
-}
+} \ No newline at end of file
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/AttributeDoesNotExist.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/AttributeDoesNotExist.java
index c13adc9251..8077cb467a 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/AttributeDoesNotExist.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/AttributeDoesNotExist.java
@@ -18,7 +18,7 @@ public class AttributeDoesNotExist extends OseeCoreException {
private static final long serialVersionUID = 1L;
- public AttributeDoesNotExist(String message) {
- super(message);
+ public AttributeDoesNotExist(String message, Object... args) {
+ super(message, args);
}
} \ No newline at end of file
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/BranchDoesNotExist.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/BranchDoesNotExist.java
index aa2bcc5032..97888e4520 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/BranchDoesNotExist.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/BranchDoesNotExist.java
@@ -16,11 +16,7 @@ package org.eclipse.osee.framework.core.exception;
public class BranchDoesNotExist extends OseeCoreException {
private static final long serialVersionUID = -6197324585250025613L;
- public BranchDoesNotExist(String message) {
- super(message);
- }
-
- public BranchDoesNotExist(String message, Throwable cause) {
- super(message, cause);
+ public BranchDoesNotExist(String message, Object... args) {
+ super(message, args);
}
} \ No newline at end of file
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/BranchMergeException.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/BranchMergeException.java
index c8b61fab5c..47c16b7677 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/BranchMergeException.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/BranchMergeException.java
@@ -17,7 +17,7 @@ public class BranchMergeException extends OseeCoreException {
private static final long serialVersionUID = 1L;
- public BranchMergeException(String message) {
- super(message);
+ public BranchMergeException(String message, Object... args) {
+ super(message, args);
}
}
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/MultipleArtifactsExist.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/MultipleArtifactsExist.java
index f42887c7cd..7c77fdb402 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/MultipleArtifactsExist.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/MultipleArtifactsExist.java
@@ -17,7 +17,7 @@ public class MultipleArtifactsExist extends OseeCoreException {
private static final long serialVersionUID = 1L;
- public MultipleArtifactsExist(String message) {
- super(message);
+ public MultipleArtifactsExist(String message, Object... args) {
+ super(message, args);
}
}
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/MultipleAttributesExist.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/MultipleAttributesExist.java
index 4cea22c694..eeef19de7e 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/MultipleAttributesExist.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/MultipleAttributesExist.java
@@ -18,7 +18,7 @@ public class MultipleAttributesExist extends OseeCoreException {
private static final long serialVersionUID = 1L;
- public MultipleAttributesExist(String message) {
- super(message);
+ public MultipleAttributesExist(String message, Object... args) {
+ super(message, args);
}
} \ No newline at end of file
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/MultipleBranchesExist.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/MultipleBranchesExist.java
index 09e84799c9..5b1288ca1c 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/MultipleBranchesExist.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/MultipleBranchesExist.java
@@ -17,7 +17,7 @@ public class MultipleBranchesExist extends OseeCoreException {
private static final long serialVersionUID = 1L;
- public MultipleBranchesExist(String message) {
- super(message);
+ public MultipleBranchesExist(String message, Object... args) {
+ super(message, args);
}
}
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeAccessDeniedException.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeAccessDeniedException.java
index a1d21284e6..efc96f7542 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeAccessDeniedException.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeAccessDeniedException.java
@@ -17,7 +17,7 @@ public class OseeAccessDeniedException extends OseeCoreException {
private static final long serialVersionUID = 1L;
- public OseeAccessDeniedException(String message) {
- super(message);
+ public OseeAccessDeniedException(String message, Object... args) {
+ super(message, args);
}
}
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeArgumentException.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeArgumentException.java
index 0119b09433..c6a083532d 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeArgumentException.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeArgumentException.java
@@ -17,7 +17,7 @@ public class OseeArgumentException extends OseeCoreException {
private static final long serialVersionUID = 1L;
- public OseeArgumentException(String message) {
- super(message);
+ public OseeArgumentException(String message, Object... args) {
+ super(message, args);
}
}
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeAuthenticationException.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeAuthenticationException.java
index 0d2f1e9c08..c107695c1e 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeAuthenticationException.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeAuthenticationException.java
@@ -27,8 +27,8 @@ public class OseeAuthenticationException extends OseeCoreException {
private final AuthenticationErrorCode errorCode;
- public OseeAuthenticationException(String message) {
- super(message);
+ public OseeAuthenticationException(String message, Object... args) {
+ super(message, args);
this.errorCode = null;
}
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeAuthenticationRequiredException.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeAuthenticationRequiredException.java
index bbcf803f34..d06bed2edf 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeAuthenticationRequiredException.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeAuthenticationRequiredException.java
@@ -17,7 +17,7 @@ public class OseeAuthenticationRequiredException extends OseeDataStoreException
private static final long serialVersionUID = 1890728724625261131L;
- public OseeAuthenticationRequiredException(String message) {
- super(message);
+ public OseeAuthenticationRequiredException(String message, Object... args) {
+ super(message, args);
}
} \ No newline at end of file
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeCoreException.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeCoreException.java
index def5a31f57..3bee37961d 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeCoreException.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeCoreException.java
@@ -13,6 +13,7 @@ package org.eclipse.osee.framework.core.exception;
import org.eclipse.core.runtime.CoreException;
import org.eclipse.core.runtime.IStatus;
import org.eclipse.core.runtime.Status;
+import org.eclipse.osee.framework.jdk.core.util.Collections;
/**
* @author Ryan D. Brooks
@@ -20,8 +21,17 @@ import org.eclipse.core.runtime.Status;
public class OseeCoreException extends CoreException {
private static final long serialVersionUID = 1L;
- public OseeCoreException(String message) {
- super(new Status(IStatus.ERROR, "OSEE", message));
+ public OseeCoreException(String message, Object... args) {
+ super(new Status(IStatus.ERROR, "OSEE", formatMessage(message, args)));
+ }
+
+ private static String formatMessage(String message, Object... args) {
+ try {
+ return String.format(message, args);
+ } catch (RuntimeException ex) {
+ return String.format("exception message could not be formatted: [%s] with the following arguments [%s]",
+ message, Collections.toString(",", args));
+ }
}
public OseeCoreException(String message, Throwable cause) {
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeDataStoreException.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeDataStoreException.java
index 0686995dc5..5f064627b7 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeDataStoreException.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeDataStoreException.java
@@ -16,7 +16,7 @@ package org.eclipse.osee.framework.core.exception;
public class OseeDataStoreException extends OseeCoreException {
private static final long serialVersionUID = 7339636628746394923L;
- public OseeDataStoreException(String message) {
- super(message);
+ public OseeDataStoreException(String message, Object... args) {
+ super(message, args);
}
} \ No newline at end of file
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeInvalidInheritanceException.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeInvalidInheritanceException.java
index df29e9a92a..eb153ca85f 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeInvalidInheritanceException.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeInvalidInheritanceException.java
@@ -14,7 +14,7 @@ public class OseeInvalidInheritanceException extends OseeCoreException {
private static final long serialVersionUID = -4553986819597790648L;
- public OseeInvalidInheritanceException(String message) {
- super(message);
+ public OseeInvalidInheritanceException(String message, Object... args) {
+ super(message, args);
}
}
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeNotFoundException.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeNotFoundException.java
index 96a8bba95e..d824baec5f 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeNotFoundException.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeNotFoundException.java
@@ -10,8 +10,6 @@
*******************************************************************************/
package org.eclipse.osee.framework.core.exception;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
/**
* @author Ryan D. Brooks
@@ -20,19 +18,7 @@ public class OseeNotFoundException extends OseeCoreException {
private static final long serialVersionUID = 3496442169445903235L;
- public OseeNotFoundException(String message) {
- super(new Status(IStatus.ERROR, "OSEE", message));
- }
-
- public OseeNotFoundException(String message, Throwable cause) {
- super(new Status(IStatus.ERROR, "OSEE", message, cause));
- }
-
- public OseeNotFoundException(Throwable cause) {
- super(new Status(IStatus.ERROR, "OSEE", cause.getMessage(), cause));
- }
-
- public OseeNotFoundException(IStatus status) {
- super(status);
+ public OseeNotFoundException(String message, Object... args) {
+ super(message, args);
}
} \ No newline at end of file
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeStateException.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeStateException.java
index 81d8e5e861..33ffe09be1 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeStateException.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeStateException.java
@@ -17,7 +17,7 @@ public class OseeStateException extends OseeCoreException {
private static final long serialVersionUID = 1L;
- public OseeStateException(String message) {
- super(message);
+ public OseeStateException(String message, Object... args) {
+ super(message, args);
}
}
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeTypeDoesNotExist.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeTypeDoesNotExist.java
index 52aa9d2672..f33ea56706 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeTypeDoesNotExist.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeTypeDoesNotExist.java
@@ -17,7 +17,7 @@ public class OseeTypeDoesNotExist extends OseeCoreException {
private static final long serialVersionUID = 1L;
- public OseeTypeDoesNotExist(String message) {
- super(message);
+ public OseeTypeDoesNotExist(String message, Object... args) {
+ super(message, args);
}
}
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeWrappedException.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeWrappedException.java
index 818af1964c..98d95f6d85 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeWrappedException.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/OseeWrappedException.java
@@ -16,10 +16,6 @@ package org.eclipse.osee.framework.core.exception;
public class OseeWrappedException extends OseeCoreException {
private static final long serialVersionUID = 1L;
- public OseeWrappedException(String message) {
- super(message);
- }
-
public OseeWrappedException(String message, Throwable cause) {
super(message, cause);
}
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/TransactionDoesNotExist.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/TransactionDoesNotExist.java
index d958307d57..a876ad9ebf 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/TransactionDoesNotExist.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/TransactionDoesNotExist.java
@@ -16,11 +16,7 @@ package org.eclipse.osee.framework.core.exception;
public class TransactionDoesNotExist extends OseeCoreException {
private static final long serialVersionUID = -6197324585250025613L;
- public TransactionDoesNotExist(String message) {
- super(message);
- }
-
- public TransactionDoesNotExist(String message, Throwable cause) {
- super(message, cause);
+ public TransactionDoesNotExist(String message, Object... args) {
+ super(message, args);
}
} \ No newline at end of file
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/UserInDatabaseMultipleTimes.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/UserInDatabaseMultipleTimes.java
index 2aeb2e2598..209487d196 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/UserInDatabaseMultipleTimes.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/UserInDatabaseMultipleTimes.java
@@ -18,11 +18,7 @@ package org.eclipse.osee.framework.core.exception;
public class UserInDatabaseMultipleTimes extends OseeCoreException {
private static final long serialVersionUID = 1L;
- public UserInDatabaseMultipleTimes(String message) {
- super(message);
- }
-
- public UserInDatabaseMultipleTimes(String message, Throwable cause) {
- super(message, cause);
+ public UserInDatabaseMultipleTimes(String message, Object... args) {
+ super(message, args);
}
} \ No newline at end of file
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/UserNotInDatabase.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/UserNotInDatabase.java
index f2260fe341..ac6519c95a 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/UserNotInDatabase.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/exception/UserNotInDatabase.java
@@ -18,11 +18,7 @@ package org.eclipse.osee.framework.core.exception;
public class UserNotInDatabase extends OseeCoreException {
private static final long serialVersionUID = 1L;
- public UserNotInDatabase(String message) {
- super(message);
- }
-
- public UserNotInDatabase(String message, Throwable cause) {
- super(message, cause);
+ public UserNotInDatabase(String message, Object... args) {
+ super(message, args);
}
} \ No newline at end of file
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/util/Conditions.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/util/Conditions.java
index 273fbf824b..e81ae67c1d 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/util/Conditions.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/util/Conditions.java
@@ -27,28 +27,28 @@ public final class Conditions {
public static void checkNotNull(Object object, String objectName) throws OseeCoreException {
if (object == null) {
- throw new OseeArgumentException(String.format("%s cannot be null", objectName));
+ throw new OseeArgumentException("%s cannot be null", objectName);
}
}
public static void checkNotNull(Object object, String objectName, String details, Object... data) throws OseeCoreException {
if (object == null) {
String message = String.format(details, data);
- throw new OseeArgumentException(String.format("%s cannot be null - %s", objectName, message));
+ throw new OseeArgumentException("%s cannot be null - %s", objectName, message);
}
}
public static void checkNotNullOrEmpty(String object, String objectName) throws OseeCoreException {
checkNotNull(object, objectName);
if (object.length() == 0) {
- throw new OseeArgumentException(String.format("%s cannot be empty", objectName));
+ throw new OseeArgumentException("%s cannot be empty", objectName);
}
}
public static void checkNotNullOrEmpty(Collection<? extends Object> collection, String objectName) throws OseeCoreException {
checkNotNull(collection, objectName);
if (collection.isEmpty()) {
- throw new OseeArgumentException(String.format("%s cannot be empty", objectName));
+ throw new OseeArgumentException("%s cannot be empty", objectName);
}
}
@@ -56,13 +56,13 @@ public final class Conditions {
checkNotNull(object, objectName);
if (object.length() == 0) {
String message = String.format(details, data);
- throw new OseeArgumentException(String.format("%s cannot be empty - %s", objectName, message));
+ throw new OseeArgumentException("%s cannot be empty - %s", objectName, message);
}
}
public static void checkExpressionFailOnTrue(boolean result, String message, Object... data) throws OseeCoreException {
if (result) {
- throw new OseeArgumentException(String.format(message, data));
+ throw new OseeArgumentException(message, data);
}
}
@@ -85,7 +85,7 @@ public final class Conditions {
if (toCheck != null) {
for (Object item : toCheck) {
if (item == null) {
- throw new OseeArgumentException(String.format(message, data));
+ throw new OseeArgumentException(message, data);
}
}
} else {
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/util/HttpMessage.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/util/HttpMessage.java
index 8e353c36fa..1b2ecb0560 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/util/HttpMessage.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/util/HttpMessage.java
@@ -44,7 +44,7 @@ public final class HttpMessage {
return service.convert(new ByteArrayInputStream(buffer.toByteArray()), responseId);
}
} else {
- throw new OseeCoreException(String.format("Request [%s] failed.", urlString));
+ throw new OseeCoreException("Request [%s] failed.", urlString);
}
} catch (Exception ex) {
OseeExceptions.wrapAndThrow(ex);
diff --git a/plugins/org.eclipse.osee.framework.database.init/src/org/eclipse/osee/framework/database/init/SkynetDbBranchDataImport.java b/plugins/org.eclipse.osee.framework.database.init/src/org/eclipse/osee/framework/database/init/SkynetDbBranchDataImport.java
index 042ea71f60..17dc5abc24 100644
--- a/plugins/org.eclipse.osee.framework.database.init/src/org/eclipse/osee/framework/database/init/SkynetDbBranchDataImport.java
+++ b/plugins/org.eclipse.osee.framework.database.init/src/org/eclipse/osee/framework/database/init/SkynetDbBranchDataImport.java
@@ -106,9 +106,8 @@ public class SkynetDbBranchDataImport implements IDbInitializationTask {
element.getDeclaringExtension().getUniqueIdentifier());
} else {
throw new OseeDataStoreException(
- String.format(
- "Branch import error - cannot import twice into a branch - [%s] was already specified by [%s] ",
- branchName, selectedBranches.get(branchName.toLowerCase())));
+ "Branch import error - cannot import twice into a branch - [%s] was already specified by [%s] ",
+ branchName, selectedBranches.get(branchName.toLowerCase()));
}
}
}
@@ -165,4 +164,4 @@ public class SkynetDbBranchDataImport implements IDbInitializationTask {
return exchangeFile;
}
}
-}
+} \ No newline at end of file
diff --git a/plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/core/SupportedDatabase.java b/plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/core/SupportedDatabase.java
index a44632029f..618f666860 100644
--- a/plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/core/SupportedDatabase.java
+++ b/plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/core/SupportedDatabase.java
@@ -39,7 +39,7 @@ public enum SupportedDatabase {
} else if (lowerCaseName.contains(SupportedDatabase.postgresql.toString())) {
toReturn = SupportedDatabase.postgresql;
} else {
- throw new OseeDataStoreException("Unsupported database type: " + dbName);
+ throw new OseeDataStoreException("Unsupported database type [%s] ", dbName);
}
} catch (SQLException ex) {
OseeExceptions.wrapAndThrow(ex);
diff --git a/plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/internal/DatabaseInfoProvider.java b/plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/internal/DatabaseInfoProvider.java
index 2cdfc1363c..39e368959a 100644
--- a/plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/internal/DatabaseInfoProvider.java
+++ b/plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/internal/DatabaseInfoProvider.java
@@ -81,8 +81,8 @@ public class DatabaseInfoProvider {
} finally {
tracker.close();
}
- throw new OseeDataStoreException(String.format(
+ throw new OseeDataStoreException(
"DB connection information was not found for: [%s]\n Available connection ids are: [%s]\n", serverIdToFind,
- infoKeys));
+ infoKeys);
}
}
diff --git a/plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/internal/core/ConnectionFactoryProvider.java b/plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/internal/core/ConnectionFactoryProvider.java
index 4078b6e711..e5a2b11975 100644
--- a/plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/internal/core/ConnectionFactoryProvider.java
+++ b/plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/internal/core/ConnectionFactoryProvider.java
@@ -46,6 +46,6 @@ public class ConnectionFactoryProvider {
} finally {
serviceTracker.close();
}
- throw new OseeNotFoundException(String.format("Unable to find connection factory with driver [%s]", driver));
+ throw new OseeNotFoundException("Unable to find connection factory with driver [%s]", driver);
}
}
diff --git a/plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/internal/core/OseeConnectionPoolImpl.java b/plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/internal/core/OseeConnectionPoolImpl.java
index 84a16a28cc..ac7a12f71b 100644
--- a/plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/internal/core/OseeConnectionPoolImpl.java
+++ b/plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/internal/core/OseeConnectionPoolImpl.java
@@ -69,7 +69,8 @@ public class OseeConnectionPoolImpl {
if (connections.size() >= MAX_CONNECTIONS_PER_CLIENT) {
throw new OseeDataStoreException(
- "This client has reached the maximum number of allowed simultaneous database connections of : " + MAX_CONNECTIONS_PER_CLIENT);
+ "This client has reached the maximum number of allowed simultaneous database connections of %d.",
+ MAX_CONNECTIONS_PER_CLIENT);
}
OseeConnectionImpl connection = getOseeConnection();
connections.add(connection);
diff --git a/plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/internal/core/OseeDatabaseServiceImpl.java b/plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/internal/core/OseeDatabaseServiceImpl.java
index e41f76905a..69e06d75ee 100644
--- a/plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/internal/core/OseeDatabaseServiceImpl.java
+++ b/plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/internal/core/OseeDatabaseServiceImpl.java
@@ -160,7 +160,7 @@ public class OseeDatabaseServiceImpl implements IOseeDatabaseService {
OseeLog.log(Activator.class, Level.SEVERE, "This is the nested exception", exlist);
}
throw new OseeCoreException(
- "sql update failed: \n" + query + "\n" + StatementUtil.getBatchErrorMessage(dataList), ex);
+ "sql update failed: \n%s\n%s", query, StatementUtil.getBatchErrorMessage(dataList), ex);
} finally {
StatementUtil.close(preparedStatement);
}
diff --git a/plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/internal/core/StatementUtil.java b/plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/internal/core/StatementUtil.java
index 16edb6c9d5..42df248092 100644
--- a/plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/internal/core/StatementUtil.java
+++ b/plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/internal/core/StatementUtil.java
@@ -92,8 +92,8 @@ public class StatementUtil {
if (dataValue instanceof String) {
int length = ((String) dataValue).length();
if (length > 4000) {
- throw new OseeDataStoreException(
- "SQL data value length must be <= 4000 not " + length + "\nValue: " + dataValue);
+ throw new OseeDataStoreException("SQL data value length must be <= 4000 not %d\nValue: %s", length,
+ dataValue);
}
}
diff --git a/plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/operation/ConsolidateArtifactVersionTxOperation.java b/plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/operation/ConsolidateArtifactVersionTxOperation.java
index 18e548ed81..2f164050e6 100644
--- a/plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/operation/ConsolidateArtifactVersionTxOperation.java
+++ b/plugins/org.eclipse.osee.framework.database/src/org/eclipse/osee/framework/database/operation/ConsolidateArtifactVersionTxOperation.java
@@ -270,7 +270,7 @@ public class ConsolidateArtifactVersionTxOperation extends AbstractDbTxOperation
ModificationType.MERGED)) {
addToUpdateAddresssing(modType, netGammaId, modType, transactionId, obsoleteGammaId);
} else {
- throw new OseeStateException("unexpected mod type: " + modType);
+ throw new OseeStateException("unexpected mod type [%s]", modType);
}
} else {
if (modType.matches(ModificationType.NEW, ModificationType.INTRODUCED, ModificationType.MODIFIED)) {
@@ -280,7 +280,7 @@ public class ConsolidateArtifactVersionTxOperation extends AbstractDbTxOperation
addToUpdateAddresssing(modType, netGammaId, modType, transactionId, obsoleteGammaId);
}
} else {
- throw new OseeStateException("unexpected mod type: " + modType);
+ throw new OseeStateException("unexpected mod type [%s]", modType);
}
}
diff --git a/plugins/org.eclipse.osee.framework.manager.servlet/src/org/eclipse/osee/framework/manager/servlet/DataServlet.java b/plugins/org.eclipse.osee.framework.manager.servlet/src/org/eclipse/osee/framework/manager/servlet/DataServlet.java
index 0c09b567ae..50832a5b7c 100644
--- a/plugins/org.eclipse.osee.framework.manager.servlet/src/org/eclipse/osee/framework/manager/servlet/DataServlet.java
+++ b/plugins/org.eclipse.osee.framework.manager.servlet/src/org/eclipse/osee/framework/manager/servlet/DataServlet.java
@@ -95,7 +95,7 @@ public class DataServlet extends UnsecuredOseeHttpServlet {
}
}
}
- throw new OseeNotFoundException(String.format("Unable to find [%s]", key));
+ throw new OseeNotFoundException("Unable to find [%s]", key);
}
}
}
diff --git a/plugins/org.eclipse.osee.framework.manager.servlet/src/org/eclipse/osee/framework/manager/servlet/OseeCacheServlet.java b/plugins/org.eclipse.osee.framework.manager.servlet/src/org/eclipse/osee/framework/manager/servlet/OseeCacheServlet.java
index 73b0ef8129..6517347114 100644
--- a/plugins/org.eclipse.osee.framework.manager.servlet/src/org/eclipse/osee/framework/manager/servlet/OseeCacheServlet.java
+++ b/plugins/org.eclipse.osee.framework.manager.servlet/src/org/eclipse/osee/framework/manager/servlet/OseeCacheServlet.java
@@ -245,7 +245,7 @@ public class OseeCacheServlet extends UnsecuredOseeHttpServlet {
transalatorId = CoreTranslatorId.RELATION_TYPE_CACHE_UPDATE_RESPONSE;
break;
default:
- throw new OseeArgumentException(String.format("Invalid cacheId [%s]", updateRequest.getCacheId()));
+ throw new OseeArgumentException("Invalid cacheId [%s]", updateRequest.getCacheId());
}
return new Pair<Object, ITranslatorId>(response, transalatorId);
}
diff --git a/plugins/org.eclipse.osee.framework.manager.servlet/src/org/eclipse/osee/framework/manager/servlet/UnsubscribeTransaction.java b/plugins/org.eclipse.osee.framework.manager.servlet/src/org/eclipse/osee/framework/manager/servlet/UnsubscribeTransaction.java
index f6f6b8f240..8119b6a375 100644
--- a/plugins/org.eclipse.osee.framework.manager.servlet/src/org/eclipse/osee/framework/manager/servlet/UnsubscribeTransaction.java
+++ b/plugins/org.eclipse.osee.framework.manager.servlet/src/org/eclipse/osee/framework/manager/servlet/UnsubscribeTransaction.java
@@ -76,9 +76,9 @@ public final class UnsubscribeTransaction extends AbstractDbTxOperation {
int modType = chStmt.getInt("mod_type");
return ensureNotAlreadyDeleted(modType);
} else {
- throw new OseeStateException(String.format(
+ throw new OseeStateException(
"No existing relation (deleted or otherwise) was found for group [%s] and user [%s].",
- unsubscribeData.getGroupId(), unsubscribeData.getUserId()));
+ unsubscribeData.getGroupId(), unsubscribeData.getUserId());
}
} finally {
Lib.close(chStmt);
diff --git a/plugins/org.eclipse.osee.framework.manager.servlet/src/org/eclipse/osee/framework/manager/servlet/ats/AtsResourceLocatorProvider.java b/plugins/org.eclipse.osee.framework.manager.servlet/src/org/eclipse/osee/framework/manager/servlet/ats/AtsResourceLocatorProvider.java
index 0192d83a9d..a0cc3b4ff3 100644
--- a/plugins/org.eclipse.osee.framework.manager.servlet/src/org/eclipse/osee/framework/manager/servlet/ats/AtsResourceLocatorProvider.java
+++ b/plugins/org.eclipse.osee.framework.manager.servlet/src/org/eclipse/osee/framework/manager/servlet/ats/AtsResourceLocatorProvider.java
@@ -45,7 +45,7 @@ public class AtsResourceLocatorProvider implements IResourceLocatorProvider {
throw new MalformedLocatorException(ex);
}
} else {
- throw new MalformedLocatorException(String.format("Invalid path hint: [%s]", path));
+ throw new MalformedLocatorException("Invalid path hint: [%s]", path);
}
return new ResourceLocator(uri);
}
diff --git a/plugins/org.eclipse.osee.framework.manager.servlet/src/org/eclipse/osee/framework/manager/servlet/ats/AtsXmlSearch.java b/plugins/org.eclipse.osee.framework.manager.servlet/src/org/eclipse/osee/framework/manager/servlet/ats/AtsXmlSearch.java
index 61f7ccfae1..6bfd982109 100644
--- a/plugins/org.eclipse.osee.framework.manager.servlet/src/org/eclipse/osee/framework/manager/servlet/ats/AtsXmlSearch.java
+++ b/plugins/org.eclipse.osee.framework.manager.servlet/src/org/eclipse/osee/framework/manager/servlet/ats/AtsXmlSearch.java
@@ -75,7 +75,7 @@ public class AtsXmlSearch {
} else if (IdUtils.isValidHRID(id)) {
builder.append("workflowHrid=");
} else {
- throw new OseeCoreException(String.format("Invalid id [%s]", id));
+ throw new OseeCoreException("Invalid id [%s]", id);
}
if (builder.length() > 0) {
builder.append("\"" + id + "\"");
diff --git a/plugins/org.eclipse.osee.framework.manager.servlet/src/org/eclipse/osee/framework/manager/servlet/data/DefaultOseeArtifact.java b/plugins/org.eclipse.osee.framework.manager.servlet/src/org/eclipse/osee/framework/manager/servlet/data/DefaultOseeArtifact.java
index 2458d6a559..abad7d6a7b 100644
--- a/plugins/org.eclipse.osee.framework.manager.servlet/src/org/eclipse/osee/framework/manager/servlet/data/DefaultOseeArtifact.java
+++ b/plugins/org.eclipse.osee.framework.manager.servlet/src/org/eclipse/osee/framework/manager/servlet/data/DefaultOseeArtifact.java
@@ -37,9 +37,9 @@ public class DefaultOseeArtifact {
}
if (!Strings.isValid(artifactGuid) || artifactBranchId < 1) {
- throw new OseeStateException(String.format(
+ throw new OseeStateException(
"OSEE default server page not found. Ensure values exist in OseeInfo table for [%s] and [%s] keys.",
- OSEE_DEFAULT_SERVER_PAGE_GUID_KEY, OSEE_DEFAULT_SERVER_PAGE_BRANCH_ID));
+ OSEE_DEFAULT_SERVER_PAGE_GUID_KEY, OSEE_DEFAULT_SERVER_PAGE_BRANCH_ID);
}
return new Pair<String, String>(artifactGuid, String.valueOf(artifactBranchId));
}
diff --git a/plugins/org.eclipse.osee.framework.messaging/src/org/eclipse/osee/framework/messaging/internal/activemq/ActiveMqUtil.java b/plugins/org.eclipse.osee.framework.messaging/src/org/eclipse/osee/framework/messaging/internal/activemq/ActiveMqUtil.java
index 2e973ca7db..f996c6c0f7 100644
--- a/plugins/org.eclipse.osee.framework.messaging/src/org/eclipse/osee/framework/messaging/internal/activemq/ActiveMqUtil.java
+++ b/plugins/org.eclipse.osee.framework.messaging/src/org/eclipse/osee/framework/messaging/internal/activemq/ActiveMqUtil.java
@@ -66,7 +66,7 @@ class ActiveMqUtil {
} else if (body instanceof Serializable) {
return session.createObjectMessage((Serializable) body);
} else {
- throw new OseeCoreException(String.format("Unsupported java type [%s]", body.getClass().getName()));
+ throw new OseeCoreException("Unsupported java type [%s]", body.getClass().getName());
}
}
diff --git a/plugins/org.eclipse.osee.framework.resource.locator.attribute/src/org/eclipse/osee/framework/resource/locator/attribute/AttributeLocatorProvider.java b/plugins/org.eclipse.osee.framework.resource.locator.attribute/src/org/eclipse/osee/framework/resource/locator/attribute/AttributeLocatorProvider.java
index 8ee0cd0a19..7878f1e2f1 100644
--- a/plugins/org.eclipse.osee.framework.resource.locator.attribute/src/org/eclipse/osee/framework/resource/locator/attribute/AttributeLocatorProvider.java
+++ b/plugins/org.eclipse.osee.framework.resource.locator.attribute/src/org/eclipse/osee/framework/resource/locator/attribute/AttributeLocatorProvider.java
@@ -53,7 +53,7 @@ public class AttributeLocatorProvider implements IResourceLocatorProvider {
throw new MalformedLocatorException(ex);
}
} else {
- throw new MalformedLocatorException(String.format("Invalid path hint: [%s]", path));
+ throw new MalformedLocatorException("Invalid path hint: [%s]", path);
}
return new ResourceLocator(uri);
}
diff --git a/plugins/org.eclipse.osee.framework.resource.management/src/org/eclipse/osee/framework/resource/management/exception/MalformedLocatorException.java b/plugins/org.eclipse.osee.framework.resource.management/src/org/eclipse/osee/framework/resource/management/exception/MalformedLocatorException.java
index 71b0d842ec..3cae53bbc8 100644
--- a/plugins/org.eclipse.osee.framework.resource.management/src/org/eclipse/osee/framework/resource/management/exception/MalformedLocatorException.java
+++ b/plugins/org.eclipse.osee.framework.resource.management/src/org/eclipse/osee/framework/resource/management/exception/MalformedLocatorException.java
@@ -23,8 +23,8 @@ public class MalformedLocatorException extends OseeCoreException {
super(message, cause);
}
- public MalformedLocatorException(String message) {
- super(message);
+ public MalformedLocatorException(String message, Object... args) {
+ super(message, args);
}
public MalformedLocatorException(Throwable cause) {
diff --git a/plugins/org.eclipse.osee.framework.resource.management/src/org/eclipse/osee/framework/resource/management/internal/ResourceLocatorManager.java b/plugins/org.eclipse.osee.framework.resource.management/src/org/eclipse/osee/framework/resource/management/internal/ResourceLocatorManager.java
index 6a37211dc3..20243df12e 100644
--- a/plugins/org.eclipse.osee.framework.resource.management/src/org/eclipse/osee/framework/resource/management/internal/ResourceLocatorManager.java
+++ b/plugins/org.eclipse.osee.framework.resource.management/src/org/eclipse/osee/framework/resource/management/internal/ResourceLocatorManager.java
@@ -75,8 +75,8 @@ public class ResourceLocatorManager implements IResourceLocatorManager {
}
}
if (toReturn == null) {
- throw new MalformedLocatorException(String.format("Error finding locator for [%s] in [%s]", protocol,
- resourceLocatorProviders));
+ throw new MalformedLocatorException("Error finding locator for [%s] in [%s]", protocol,
+ resourceLocatorProviders);
}
return toReturn;
}
diff --git a/plugins/org.eclipse.osee.framework.resource.management/src/org/eclipse/osee/framework/resource/management/internal/ResourceManager.java b/plugins/org.eclipse.osee.framework.resource.management/src/org/eclipse/osee/framework/resource/management/internal/ResourceManager.java
index 33ea2cc42a..ed2c02573f 100644
--- a/plugins/org.eclipse.osee.framework.resource.management/src/org/eclipse/osee/framework/resource/management/internal/ResourceManager.java
+++ b/plugins/org.eclipse.osee.framework.resource.management/src/org/eclipse/osee/framework/resource/management/internal/ResourceManager.java
@@ -90,7 +90,7 @@ public class ResourceManager implements IResourceManager {
}
if (toReturn == null) {
- throw new OseeNotFoundException(String.format("Invalid Locator: [%s]", locator));
+ throw new OseeNotFoundException("Invalid Locator: [%s]", locator);
}
return toReturn;
}
diff --git a/plugins/org.eclipse.osee.framework.resource.management/src/org/eclipse/osee/framework/resource/management/util/OptionsProcessor.java b/plugins/org.eclipse.osee.framework.resource.management/src/org/eclipse/osee/framework/resource/management/util/OptionsProcessor.java
index ae73ae7650..e0ff142448 100644
--- a/plugins/org.eclipse.osee.framework.resource.management/src/org/eclipse/osee/framework/resource/management/util/OptionsProcessor.java
+++ b/plugins/org.eclipse.osee.framework.resource.management/src/org/eclipse/osee/framework/resource/management/util/OptionsProcessor.java
@@ -77,7 +77,7 @@ public class OptionsProcessor {
File storageFile = new File(fileuri);
if (!overwrite) {
if (storageFile.exists()) {
- throw new OseeStateException(String.format("The file [%s] already exists.", storageFile.getAbsolutePath()));
+ throw new OseeStateException("The file [%s] already exists.", storageFile.getAbsolutePath());
}
}
File parent = storageFile.getParentFile();
diff --git a/plugins/org.eclipse.osee.framework.resource.provider.attribute/src/org/eclipse/osee/framework/resource/provider/attribute/AttributeProvider.java b/plugins/org.eclipse.osee.framework.resource.provider.attribute/src/org/eclipse/osee/framework/resource/provider/attribute/AttributeProvider.java
index 08cd35edb1..59b01dc8a9 100644
--- a/plugins/org.eclipse.osee.framework.resource.provider.attribute/src/org/eclipse/osee/framework/resource/provider/attribute/AttributeProvider.java
+++ b/plugins/org.eclipse.osee.framework.resource.provider.attribute/src/org/eclipse/osee/framework/resource/provider/attribute/AttributeProvider.java
@@ -20,6 +20,7 @@ import java.util.Arrays;
import java.util.Collection;
import org.eclipse.osee.framework.core.exception.OseeCoreException;
import org.eclipse.osee.framework.core.exception.OseeExceptions;
+import org.eclipse.osee.framework.core.exception.OseeStateException;
import org.eclipse.osee.framework.core.server.OseeServerProperties;
import org.eclipse.osee.framework.jdk.core.util.Lib;
import org.eclipse.osee.framework.resource.management.IResource;
@@ -95,7 +96,7 @@ public class AttributeProvider implements IResourceProvider {
Lib.close(inputStream);
}
if (toReturn == null) {
- throw new IllegalStateException(String.format("We failed to save resource %s.", locator.getLocation()));
+ throw new OseeStateException("We failed to save resource %s.", locator.getLocation());
}
return toReturn;
}
diff --git a/plugins/org.eclipse.osee.framework.search.engine/src/org/eclipse/osee/framework/search/engine/internal/AttributeTaggerProviderManagerImpl.java b/plugins/org.eclipse.osee.framework.search.engine/src/org/eclipse/osee/framework/search/engine/internal/AttributeTaggerProviderManagerImpl.java
index 2d098270a2..85d0dd2fdb 100644
--- a/plugins/org.eclipse.osee.framework.search.engine/src/org/eclipse/osee/framework/search/engine/internal/AttributeTaggerProviderManagerImpl.java
+++ b/plugins/org.eclipse.osee.framework.search.engine/src/org/eclipse/osee/framework/search/engine/internal/AttributeTaggerProviderManagerImpl.java
@@ -52,7 +52,7 @@ public class AttributeTaggerProviderManagerImpl implements IAttributeTaggerProvi
AttributeType attributeType = typeCache.getById(attrTypeId);
IAttributeTaggerProvider toReturn = this.attributeTaggerProviders.get(attributeType.getTaggerId());
if (toReturn == null) {
- throw new OseeStateException("No tagger found for id " + attributeType.getTaggerId());
+ throw new OseeStateException("No tagger found for id [%s]", attributeType.getTaggerId());
}
return toReturn;
}
@@ -68,5 +68,4 @@ public class AttributeTaggerProviderManagerImpl implements IAttributeTaggerProvi
IAttributeTaggerProvider provider = getProvider(attributeData.getAttrTypeId());
return provider.find(attributeData, toSearch, options);
}
-
-}
+} \ No newline at end of file
diff --git a/plugins/org.eclipse.osee.framework.server.admin/src/org/eclipse/osee/framework/server/admin/branch/BranchExportWorker.java b/plugins/org.eclipse.osee.framework.server.admin/src/org/eclipse/osee/framework/server/admin/branch/BranchExportWorker.java
index 9d3f889249..5e6c4cac82 100644
--- a/plugins/org.eclipse.osee.framework.server.admin/src/org/eclipse/osee/framework/server/admin/branch/BranchExportWorker.java
+++ b/plugins/org.eclipse.osee.framework.server.admin/src/org/eclipse/osee/framework/server/admin/branch/BranchExportWorker.java
@@ -14,6 +14,7 @@ import java.util.ArrayList;
import java.util.List;
import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.osee.framework.branch.management.ExportOptions;
+import org.eclipse.osee.framework.core.exception.OseeArgumentException;
import org.eclipse.osee.framework.database.core.ConnectionHandler;
import org.eclipse.osee.framework.database.core.IOseeStatement;
import org.eclipse.osee.framework.resource.management.Options;
@@ -75,7 +76,7 @@ public class BranchExportWorker extends BaseServerCommand {
} while (isValidArg(arg));
if (!isValidArg(exportFileName)) {
- throw new IllegalArgumentException(String.format("exportFileName was invalid: [%s]", exportFileName));
+ throw new OseeArgumentException("exportFileName was invalid: [%s]", exportFileName);
}
if (branchIds.isEmpty()) {
diff --git a/plugins/org.eclipse.osee.framework.server.admin/src/org/eclipse/osee/framework/server/admin/branch/BranchImportWorker.java b/plugins/org.eclipse.osee.framework.server.admin/src/org/eclipse/osee/framework/server/admin/branch/BranchImportWorker.java
index 3469bb85a4..c68b4e9d9c 100644
--- a/plugins/org.eclipse.osee.framework.server.admin/src/org/eclipse/osee/framework/server/admin/branch/BranchImportWorker.java
+++ b/plugins/org.eclipse.osee.framework.server.admin/src/org/eclipse/osee/framework/server/admin/branch/BranchImportWorker.java
@@ -82,9 +82,9 @@ public class BranchImportWorker extends BaseServerCommand {
for (File file : importFiles) {
if (file == null || !file.exists() || !file.canRead()) {
- throw new OseeArgumentException(String.format("File was not accessible: [%s]", file));
+ throw new OseeArgumentException("File was not accessible: [%s]", file);
} else if (file.isFile() && !Lib.isCompressed(file)) {
- throw new OseeArgumentException(String.format("Invalid File: [%s]", file));
+ throw new OseeArgumentException("Invalid File: [%s]", file);
}
}
diff --git a/plugins/org.eclipse.osee.framework.server.admin/src/org/eclipse/osee/framework/server/admin/branch/ExchangeIntegrityWorker.java b/plugins/org.eclipse.osee.framework.server.admin/src/org/eclipse/osee/framework/server/admin/branch/ExchangeIntegrityWorker.java
index c0fb906c09..83ef83e79a 100644
--- a/plugins/org.eclipse.osee.framework.server.admin/src/org/eclipse/osee/framework/server/admin/branch/ExchangeIntegrityWorker.java
+++ b/plugins/org.eclipse.osee.framework.server.admin/src/org/eclipse/osee/framework/server/admin/branch/ExchangeIntegrityWorker.java
@@ -15,6 +15,7 @@ import java.net.URI;
import java.util.ArrayList;
import java.util.List;
import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.osee.framework.core.exception.OseeArgumentException;
import org.eclipse.osee.framework.jdk.core.util.Lib;
import org.eclipse.osee.framework.resource.management.util.ResourceLocator;
import org.eclipse.osee.framework.server.admin.BaseServerCommand;
@@ -54,9 +55,9 @@ public class ExchangeIntegrityWorker extends BaseServerCommand {
for (File file : importFiles) {
if (file == null || !file.exists() || !file.canRead()) {
- throw new IllegalArgumentException(String.format("File was not accessible: [%s]", file));
+ throw new OseeArgumentException("File was not accessible: [%s]", file);
} else if (file.isFile() && !Lib.isCompressed(file)) {
- throw new IllegalArgumentException(String.format("Invalid File: [%s]", file));
+ throw new OseeArgumentException("Invalid File: [%s]", file);
}
}
diff --git a/plugins/org.eclipse.osee.framework.skynet.core.test/src/org/eclipse/osee/framework/skynet/core/test/cases/ArtifactLoaderTest.java b/plugins/org.eclipse.osee.framework.skynet.core.test/src/org/eclipse/osee/framework/skynet/core/test/cases/ArtifactLoaderTest.java
index 5f778651d7..33682c8e48 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core.test/src/org/eclipse/osee/framework/skynet/core/test/cases/ArtifactLoaderTest.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core.test/src/org/eclipse/osee/framework/skynet/core/test/cases/ArtifactLoaderTest.java
@@ -145,7 +145,7 @@ public class ArtifactLoaderTest {
ArtifactQuery.getArtifactListFromName("ArtifactLoaderTest", BranchManager.getCommonBranch(),
EXCLUDE_DELETED);
if (artifacts.size() != NUM_ARTIFACTS) {
- throw new OseeStateException("Should have loaded " + NUM_ARTIFACTS + "; only got " + artifacts.size());
+ throw new OseeStateException("Should have loaded %d not %d", NUM_ARTIFACTS, artifacts.size());
}
numThreadsCompleted++;
System.out.println("Completed " + getName() + "; NumThreads " + numThreadsCompleted);
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/OseeSystemArtifacts.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/OseeSystemArtifacts.java
index 16cf91abfb..0a6195da9f 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/OseeSystemArtifacts.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/OseeSystemArtifacts.java
@@ -65,8 +65,8 @@ public final class OseeSystemArtifacts {
artifact = ArtifactTypeManager.addArtifact(artifactType, branch, artifactName);
}
if (artifact == null) {
- throw new ArtifactDoesNotExist(
- "Artifact of type " + artifactType + " with name " + artifactName + " does not exist on branch " + branch);
+ throw new ArtifactDoesNotExist("Artifact of type [%s] with name [%s] does not exist on branch [%s]",
+ artifactType, artifactName, branch);
}
ArtifactCache.cacheByTextId(artifactType.getName() + "." + artifactName, artifact);
}
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/UserManager.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/UserManager.java
index 215464baea..30a073bc1b 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/UserManager.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/UserManager.java
@@ -133,7 +133,7 @@ public final class UserManager {
ensurePopulated();
User user = (User) ArtifactCache.getActive(userArtifactId, BranchManager.getCommonBranch());
if (user == null) {
- throw new UserNotInDatabase("User requested by artId \"" + userArtifactId + "\" was not found.");
+ throw new UserNotInDatabase("User requested by artId \"%d\" was not found.", userArtifactId);
}
return user;
}
@@ -158,7 +158,7 @@ public final class UserManager {
return tempUser;
}
}
- throw new UserNotInDatabase("User requested by name \"" + name + "\" was not found.");
+ throw new UserNotInDatabase("User requested by name \"%s\" was not found.", name);
}
private static User getFromCacheByUserId(String userId) throws OseeCoreException {
@@ -182,7 +182,7 @@ public final class UserManager {
(User) ArtifactQuery.getArtifactFromAttribute(CoreAttributeTypes.UserId, userId,
BranchManager.getCommonBranch());
} catch (ArtifactDoesNotExist ex) {
- throw new UserNotInDatabase(String.format("The user with id [%s] was not found.", userId));
+ throw new UserNotInDatabase("The user with id [%s] was not found.", userId);
}
}
return user;
@@ -201,8 +201,7 @@ public final class UserManager {
User cachedUser = cacheByUserId(user);
if (cachedUser != null) { // if duplicate user id found
OseeCoreException ex =
- new UserInDatabaseMultipleTimes(
- "User of userId \"" + user.getUserId() + "\" in datastore more than once");
+ new UserInDatabaseMultipleTimes("User of userId \"%d\" in datastore more than once", user.getUserId());
// exception if I am the duplicate user otherwise just log
if (user.getUserId().equals(ClientSessionManager.getSession().getId())) {
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/Artifact.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/Artifact.java
index 7aa5feb89b..0e17d1cf78 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/Artifact.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/Artifact.java
@@ -342,7 +342,7 @@ public class Artifact extends NamedIdentity implements IArtifact, IAdaptable, Co
public boolean hasParent() throws OseeCoreException {
int parentCount = getRelatedArtifactsUnSorted(CoreRelationTypes.Default_Hierarchical__Parent).size();
if (parentCount > 1) {
- throw new MultipleArtifactsExist(humanReadableId + " has " + parentCount + " parents");
+ throw new MultipleArtifactsExist("artifact [%s] has %d parents", humanReadableId, parentCount);
}
return parentCount == 1;
@@ -373,7 +373,7 @@ public class Artifact extends NamedIdentity implements IArtifact, IAdaptable, Co
return artifact;
}
}
- throw new ArtifactDoesNotExist("\"" + getName() + "\" has no child with the name \"" + descriptiveName + "\"");
+ throw new ArtifactDoesNotExist("artifact [%s] has no child with the name [%s]", this, descriptiveName);
}
public boolean hasChild(String descriptiveName) throws OseeCoreException {
@@ -622,13 +622,15 @@ public class Artifact extends NamedIdentity implements IArtifact, IAdaptable, Co
List<Attribute<T>> soleAttributes = getAttributes(attributeType);
if (soleAttributes.isEmpty()) {
if (!isAttributeTypeValid(attributeType)) {
- throw new OseeArgumentException(String.format(
- "The attribute type %s is not valid for artifacts of type [%s]", attributeType, getArtifactTypeName()));
+ throw new OseeArgumentException("The attribute type %s is not valid for artifacts of type [%s]",
+ attributeType, getArtifactTypeName());
}
- throw new AttributeDoesNotExist("Attribute \"" + attributeType + "\" does not exist for artifact " + getGuid());
+ throw new AttributeDoesNotExist("Attribute of type [%s] could not be found on artifact [%s] on branch [%s]",
+ attributeType.getName(), getGuid(), getBranch().getGuid());
} else if (soleAttributes.size() > 1) {
throw new MultipleAttributesExist(
- "Attribute \"" + attributeType + "\" must have exactly one instance. It currently has " + soleAttributes.size() + " for artifact " + getGuid());
+ "Attribute [%s] must have exactly one instance. It currently has %d for artifact [%s]", attributeType,
+ soleAttributes.size(), getGuid());
}
return soleAttributes.iterator().next().getValue();
}
@@ -690,7 +692,8 @@ public class Artifact extends NamedIdentity implements IArtifact, IAdaptable, Co
return value;
} else if (soleAttributes.size() > 1) {
throw new MultipleAttributesExist(
- "Attribute \"" + attributeType + "\" must have exactly one instance. It currently has " + soleAttributes.size() + " for artifact " + getGuid());
+ "Attribute [%s] must have exactly one instance. It currently has %d for artifact [%s]", attributeType,
+ soleAttributes.size(), getGuid());
} else {
return defaultReturnValue;
}
@@ -991,12 +994,11 @@ public class Artifact extends NamedIdentity implements IArtifact, IAdaptable, Co
private final void persistAttributes(SkynetTransaction transaction) throws OseeCoreException {
if (!UserManager.duringMainUserCreation() && !getAccessControlService().hasPermission(getBranch(),
PermissionEnum.WRITE)) {
- throw new OseeArgumentException(
- "No write permissions for the branch that this artifact belongs to:" + getBranch());
+ throw new OseeArgumentException("No write permissions for the branch [%s] that this artifact belongs to",
+ getBranch());
}
if (isHistorical()) {
- throw new OseeArgumentException(
- "The artifact " + getGuid() + " must be at the head of the branch to be edited.");
+ throw new OseeArgumentException("The artifact [%s] must be at the head of the branch to be edited.", getGuid());
}
if (hasDirtyAttributes() || hasDirtyArtifactType()) {
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/ArtifactCache.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/ArtifactCache.java
index 59a4dd0578..a99223ef5c 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/ArtifactCache.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/ArtifactCache.java
@@ -105,15 +105,15 @@ public final class ArtifactCache {
*/
public static Artifact cacheByTextId(String key, Artifact artifact) throws OseeCoreException {
if (artifact.isHistorical()) {
- throw new OseeArgumentException(String.format("historical artifact cannot be cached by text [%s]", key));
+ throw new OseeArgumentException("historical artifact cannot be cached by text [%s]", key);
}
return ACTIVE_CACHE.cacheByText(key, artifact);
}
public static void cacheByStaticId(String staticId, Artifact artifact) throws OseeCoreException {
if (artifact.isHistorical()) {
- throw new OseeArgumentException(String.format("historical artifact cannot be cached by staticId [%s]",
- staticId));
+ throw new OseeArgumentException("historical artifact cannot be cached by staticId [%s]",
+ staticId);
}
ACTIVE_CACHE.cacheByStaticId(staticId, artifact);
}
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/ArtifactFactory.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/ArtifactFactory.java
index 2d27ae5ae7..43503d9f13 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/ArtifactFactory.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/ArtifactFactory.java
@@ -47,8 +47,8 @@ public abstract class ArtifactFactory {
*/
public Artifact makeNewArtifact(IOseeBranch branch, ArtifactType artifactType, String guid, String humandReadableId, ArtifactProcessor earlyArtifactInitialization) throws OseeCoreException {
if (artifactType.isAbstract()) {
- throw new OseeArgumentException(String.format("Cannot create an instance of abstract type [%s]",
- artifactType.getName()));
+ throw new OseeArgumentException("Cannot create an instance of abstract type [%s]",
+ artifactType.getName());
}
Artifact artifact = getArtifactInstance(guid, humandReadableId, BranchManager.getBranch(branch), artifactType);
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/ArtifactPersistenceManager.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/ArtifactPersistenceManager.java
index c2d84a6034..c46c6d1eea 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/ArtifactPersistenceManager.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/ArtifactPersistenceManager.java
@@ -248,8 +248,8 @@ public class ArtifactPersistenceManager {
// Only reverts relation links that don't span multiple branches. Need
// to revisit if additional functionality is needed.
if (!link.getArtifactA().getBranch().equals(link.getArtifactB().getBranch())) {
- throw new OseeArgumentException(String.format("Cannot revert Relation %d. Relation spans multiple branches",
- link.getId()));
+ throw new OseeArgumentException("Cannot revert Relation %d. Relation spans multiple branches",
+ link.getId());
}
long totalTime = System.currentTimeMillis();
Branch branch = link.getArtifactA().getBranch();
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/ArtifactTypeManager.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/ArtifactTypeManager.java
index 5ac5d8cabb..28dbeefcde 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/ArtifactTypeManager.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/ArtifactTypeManager.java
@@ -106,11 +106,11 @@ public class ArtifactTypeManager {
*/
public static ArtifactType getTypeByGuid(String guid) throws OseeCoreException {
if (!GUID.isValid(guid)) {
- throw new OseeArgumentException(String.format("[%s] is not a valid guid", guid));
+ throw new OseeArgumentException("[%s] is not a valid guid", guid);
}
ArtifactType artifactType = getCache().getByGuid(guid);
if (artifactType == null) {
- throw new OseeTypeDoesNotExist(String.format("Artifact type [%s] is not available.", guid));
+ throw new OseeTypeDoesNotExist("Artifact type [%s] is not available.", guid);
}
return artifactType;
}
@@ -122,7 +122,7 @@ public class ArtifactTypeManager {
public static ArtifactType getType(String name) throws OseeCoreException {
ArtifactType artifactType = getCache().getUniqueByName(name);
if (artifactType == null) {
- throw new OseeTypeDoesNotExist("Artifact type [" + name + "] is not available.");
+ throw new OseeTypeDoesNotExist("Artifact type [%s] is not available.", name);
}
return artifactType;
}
@@ -156,7 +156,7 @@ public class ArtifactTypeManager {
public static ArtifactType getType(int artTypeId) throws OseeCoreException {
ArtifactType artifactType = getCache().getById(artTypeId);
if (artifactType == null) {
- throw new OseeTypeDoesNotExist("Atrifact type: " + artTypeId + " is not available.");
+ throw new OseeTypeDoesNotExist("Atrifact type: %d is not available.", artTypeId);
}
return artifactType;
}
@@ -201,7 +201,8 @@ public class ArtifactTypeManager {
if (artifactCount != 0) {
throw new OseeArgumentException(
- "Can not delete artifact type " + artifactType.getName() + " because there are " + artifactCount + " existing artifacts of this type.");
+ "Can not delete artifact type [%s] because there are %d existing artifacts of this type.", artifactType,
+ artifactCount);
}
new DbTransaction() {
@@ -236,8 +237,8 @@ public class ArtifactTypeManager {
for (Artifact artifact : artifacts) {
branches.add(artifact.getBranch());
}
- throw new OseeStateException(
- "Found " + artifacts.size() + " artifact references of type " + purgeArtifactType + " on branches " + branches);
+ throw new OseeStateException("Found %d artifact references of type [%s] on branches [%s]",
+ artifacts.size(), purgeArtifactType, branches);
} else {
ChangeArtifactType.changeArtifactType(artifactMap.values(), newArtifactType);
}
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/BranchManager.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/BranchManager.java
index 4a5d7a0d6a..5bcf9adc00 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/BranchManager.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/BranchManager.java
@@ -119,10 +119,10 @@ public class BranchManager {
public static Branch getBranch(String branchName) throws OseeCoreException {
Collection<Branch> branches = getBranchesByName(branchName);
if (branches.isEmpty()) {
- throw new BranchDoesNotExist(String.format("No branch exists with the name: [%s]", branchName));
+ throw new BranchDoesNotExist("No branch exists with the name: [%s]", branchName);
}
if (branches.size() > 1) {
- throw new MultipleBranchesExist(String.format("More than 1 branch exists with the name: [%s]", branchName));
+ throw new MultipleBranchesExist("More than 1 branch exists with the name: [%s]", branchName);
}
return branches.iterator().next();
}
@@ -146,7 +146,7 @@ public class BranchManager {
public static Branch getBranchByGuid(String guid) throws OseeCoreException {
Branch branch = getCache().getByGuid(guid);
if (branch == null) {
- throw new BranchDoesNotExist(String.format("Branch with guid [%s] does not exist", guid));
+ throw new BranchDoesNotExist("Branch with guid [%s] does not exist", guid);
}
return branch;
}
@@ -194,7 +194,7 @@ public class BranchManager {
}
}
if (branch == null) {
- throw new BranchDoesNotExist("Branch could not be acquired for branch id: " + branchId);
+ throw new BranchDoesNotExist("Branch could not be acquired for branch id %d", branchId);
}
return branch;
}
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/BranchUtility.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/BranchUtility.java
index 8513d2fe58..9349759c4f 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/BranchUtility.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/BranchUtility.java
@@ -35,7 +35,7 @@ public final class BranchUtility {
}
String branchGuid = branch.getGuid();
if (!GUID.isValid(branchGuid)) {
- throw new OseeStateException(String.format("GUID for branch [%s] is invalid", branch.getId()));
+ throw new OseeStateException("GUID for branch [%s] is invalid", branch.getId());
}
return encode(branchGuid);
}
@@ -66,13 +66,13 @@ public final class BranchUtility {
if (GUID.isValid(branchGuid)) {
toReturn = cache.getByGuid(branchGuid);
if (toReturn == null) {
- throw new OseeArgumentException(String.format("Unable to find branch matching guid [%s]", branchGuid));
+ throw new OseeArgumentException("Unable to find branch matching guid [%s]", branchGuid);
}
} else {
int branchId = Integer.parseInt(Lib.getExtension(fileName));
toReturn = cache.getById(branchId);
if (toReturn == null) {
- throw new OseeArgumentException(String.format("Unable to find branch matching id [%s]", branchId));
+ throw new OseeArgumentException("Unable to find branch matching id [%s]", branchId);
}
}
return toReturn;
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/PurgeArtifacts.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/PurgeArtifacts.java
index 772a08ee55..7a1dcd7478 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/PurgeArtifacts.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/PurgeArtifacts.java
@@ -97,8 +97,8 @@ public class PurgeArtifacts extends DbTransaction {
sb.append("]\n");
}
if (failed) {
- throw new OseeCoreException(String.format(
- "Unable to purge because the following artifacts exist on child branches.\n%s", sb.toString()));
+ throw new OseeCoreException(
+ "Unable to purge because the following artifacts exist on child branches.\n%s", sb.toString());
}
} finally {
ArtifactLoader.clearQuery(connection, queryId);
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/PurgeTransactionOperation.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/PurgeTransactionOperation.java
index c57f22065a..b3d5e8d7af 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/PurgeTransactionOperation.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/PurgeTransactionOperation.java
@@ -19,6 +19,7 @@ import java.util.List;
import java.util.Set;
import java.util.logging.Level;
import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.osee.framework.core.exception.OseeArgumentException;
import org.eclipse.osee.framework.core.exception.OseeCoreException;
import org.eclipse.osee.framework.core.exception.OseeExceptions;
import org.eclipse.osee.framework.core.exception.TransactionDoesNotExist;
@@ -216,8 +217,9 @@ public class PurgeTransactionOperation extends AbstractDbTxOperation {
try {
previousTransaction = TransactionManager.getPriorTransaction(fromTransaction);
} catch (TransactionDoesNotExist ex) {
- throw new OseeCoreException(
- "You are trying to delete Transaction: " + fromTx + " which is a baseline transaction. If your intent is to delete the Branch use the delete Branch Operation. \n\nNO TRANSACTIONS WERE DELETED.");
+ throw new OseeArgumentException(
+ "You are trying to delete Transaction [%d] which is a baseline transaction. If your intent is to delete the Branch use the delete Branch Operation. \n\nNO TRANSACTIONS WERE DELETED.",
+ fromTx);
}
@@ -308,7 +310,8 @@ public class PurgeTransactionOperation extends AbstractDbTxOperation {
ConnectionHandler.runPreparedQueryFetchInt(connection, 0, TRANSACATION_GAMMA_IN_USE, queryId);
if (transaction_id > 0 && !force) {
throw new OseeCoreException(
- "The Transaction " + transaction_id + " holds a Gamma that is in use in other transactions. In order to delete this Transaction you will need to select the force check box.\n\nNO TRANSACTIONS WERE DELETED.");
+ "The Transaction %d holds a Gamma that is in use in other transactions. In order to delete this Transaction you will need to select the force check box.\n\nNO TRANSACTIONS WERE DELETED.",
+ transaction_id);
}
}
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/RevertAction.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/RevertAction.java
index bf6d801fc3..eb2bcd5b09 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/RevertAction.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/RevertAction.java
@@ -145,8 +145,8 @@ public class RevertAction {
int count2 = ConnectionHandler.runBatchUpdate(connection, DELETE_TXS_GAMMAS_REVERT, gammaIdsModifications);
if (count1 != count2) {
- throw new OseeCoreException(String.format("Revert Transaction moved %d transaction but should have moved %d",
- count1, count2));
+ throw new OseeCoreException("Revert Transaction moved %d transaction but should have moved %d",
+ count1, count2);
}
if (DEBUG) {
displayRevertResults(time, objectReverted, gammaIdsModifications, count2);
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/StaticIdManager.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/StaticIdManager.java
index 8842775a51..2ffe059052 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/StaticIdManager.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/StaticIdManager.java
@@ -97,9 +97,9 @@ public class StaticIdManager {
Set<Artifact> artifacts = getArtifactsFromArtifactCache(artifactType, staticId, branch, true);
// Exception on problems
if (artifacts.isEmpty()) {
- throw new ArtifactDoesNotExist("Can't find requested artifact \"" + staticId + "\"");
+ throw new ArtifactDoesNotExist("No artifact with static id [%s] found.", staticId);
} else if (artifacts.size() > 1) {
- throw new MultipleArtifactsExist("Expected 1 \"" + staticId + "\" artifact, retrieved " + artifacts.size());
+ throw new MultipleArtifactsExist("Expected 1 artifact with static id [%s] not %d", staticId, artifacts.size());
}
return artifacts.iterator().next();
}
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/UpdateMergeBranch.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/UpdateMergeBranch.java
index 9a1afdd82a..028b4f0c2f 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/UpdateMergeBranch.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/UpdateMergeBranch.java
@@ -175,8 +175,8 @@ public class UpdateMergeBranch extends DbTransaction {
insertGammas(connection, INSERT_ATTRIBUTE_GAMMAS, startTransactionNumber, queryId, sourceBranch, mergeBranch);
insertGammas(connection, INSERT_ARTIFACT_GAMMAS, startTransactionNumber, queryId, sourceBranch, mergeBranch);
} catch (OseeCoreException ex) {
- throw new OseeCoreException(
- "Source Branch Id: " + sourceBranch.getId() + " Artifact Ids: " + Collections.toString(",", artIds));
+ throw new OseeCoreException("Source Branch %s Artifact Ids: %s", sourceBranch.getGuid(), Collections.toString(
+ ",", artIds));
} finally {
ArtifactLoader.clearQuery(connection, queryId);
}
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/factory/UserArtifactFactory.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/factory/UserArtifactFactory.java
index c0cd272f52..2924e9b04c 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/factory/UserArtifactFactory.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/artifact/factory/UserArtifactFactory.java
@@ -40,7 +40,7 @@ public class UserArtifactFactory extends ArtifactFactory {
if (artifactType.getGuid().equals(CoreArtifactTypes.User.getGuid())) {
return new User(this, guid, humandReadableId, branch, artifactType);
}
- throw new OseeArgumentException("did not recognize the artifact type: " + artifactType.getName());
+ throw new OseeArgumentException("did not recognize the artifact type [%s]", artifactType);
}
@Override
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/attribute/AttributeExtensionManager.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/attribute/AttributeExtensionManager.java
index 27ddccfe84..f8e03e5244 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/attribute/AttributeExtensionManager.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/attribute/AttributeExtensionManager.java
@@ -74,7 +74,7 @@ public class AttributeExtensionManager {
String resolved = resolveAttributeBaseTypeId(name);
Pair<String, String> entry = instance.attributeTypeClasses.get(resolved);
if (entry == null) {
- throw new OseeArgumentException(String.format("Unable to find class for: [%s]", resolved));
+ throw new OseeArgumentException("Unable to find class for: [%s]", resolved);
}
return instance.loadClass(entry.getFirst(), entry.getSecond());
@@ -88,7 +88,7 @@ public class AttributeExtensionManager {
String resolved = resolveAttributeProviderTypeId(name);
Pair<String, String> entry = instance.attributeDataProviderClasses.get(resolved);
if (entry == null) {
- throw new OseeArgumentException(String.format("Unable to find class for: [%s]", resolved));
+ throw new OseeArgumentException("Unable to find class for: [%s]", resolved);
}
return instance.loadClass(entry.getFirst(), entry.getSecond());
}
@@ -121,9 +121,8 @@ public class AttributeExtensionManager {
}
}
if (toReturn.isEmpty()) {
- throw new OseeStateException(String.format(
- "No Objects loaded for [%s] with element names %s and attribute [%s]", extensionPointId,
- Arrays.asList(elementNames), classNameAttribute));
+ throw new OseeStateException("No Objects loaded for [%s] with element names %s and attribute [%s]",
+ extensionPointId, Arrays.asList(elementNames), classNameAttribute);
}
return toReturn;
}
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/attribute/AttributeTypeManager.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/attribute/AttributeTypeManager.java
index afc2ae6840..33cf70db6e 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/attribute/AttributeTypeManager.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/attribute/AttributeTypeManager.java
@@ -79,11 +79,11 @@ public class AttributeTypeManager {
*/
public static AttributeType getTypeByGuid(String guid) throws OseeCoreException {
if (!GUID.isValid(guid)) {
- throw new OseeArgumentException(String.format("[%s] is not a valid guid", guid));
+ throw new OseeArgumentException("[%s] is not a valid guid", guid);
}
AttributeType attributeType = getCache().getByGuid(guid);
if (attributeType == null) {
- throw new OseeTypeDoesNotExist("Attribute Type [" + guid + "] is not available.");
+ throw new OseeTypeDoesNotExist("Attribute Type [%s] is not available.", guid);
}
return attributeType;
}
@@ -98,7 +98,7 @@ public class AttributeTypeManager {
public static AttributeType getType(String name) throws OseeCoreException {
AttributeType attributeType = getCache().getUniqueByName(name);
if (attributeType == null) {
- throw new OseeTypeDoesNotExist("Attribute Type with name [" + name + "] does not exist.");
+ throw new OseeTypeDoesNotExist("Attribute Type with name [%s] does not exist.", name);
}
return attributeType;
}
@@ -109,7 +109,7 @@ public class AttributeTypeManager {
public static AttributeType getType(int attrTypeId) throws OseeCoreException {
AttributeType attributeType = getCache().getById(attrTypeId);
if (attributeType == null) {
- throw new OseeTypeDoesNotExist("Attribute type: " + attrTypeId + " is not available.");
+ throw new OseeTypeDoesNotExist("Attribute type: %d is not available.", attrTypeId);
}
return attributeType;
@@ -138,7 +138,8 @@ public class AttributeTypeManager {
ConnectionHandler.runPreparedQueryFetchInt(0, COUNT_ATTRIBUTE_OCCURRENCE, attributeType.getId());
if (attributeCount != 0) {
throw new OseeArgumentException(
- "Can not delete attribute type " + attributeType.getName() + " because there are " + attributeCount + " existing attributes of this type.");
+ "Can not delete attribute type [%s] because there are %d existing attributes of this type.", attributeType,
+ attributeCount);
}
new DbTransaction() {
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/attribute/OseeEnumTypeManager.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/attribute/OseeEnumTypeManager.java
index 6600f43938..26425e7e12 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/attribute/OseeEnumTypeManager.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/attribute/OseeEnumTypeManager.java
@@ -31,7 +31,7 @@ public class OseeEnumTypeManager {
public static OseeEnumType getType(int enumTypeId) throws OseeCoreException {
OseeEnumType oseeEnumType = getCache().getById(enumTypeId);
if (oseeEnumType == null) {
- throw new OseeTypeDoesNotExist(String.format("Osee Enum Type with id:[%s] does not exist.", enumTypeId));
+ throw new OseeTypeDoesNotExist("Osee Enum Type with id:[%s] does not exist.", enumTypeId);
}
return oseeEnumType;
}
@@ -39,8 +39,7 @@ public class OseeEnumTypeManager {
public static OseeEnumType getType(String enumTypeName) throws OseeCoreException {
OseeEnumType itemsFound = getCache().getUniqueByName(enumTypeName);
if (itemsFound == null) {
- throw new OseeTypeDoesNotExist(
- String.format("OSEE enum types matching [%s] name does not exist", enumTypeName));
+ throw new OseeTypeDoesNotExist("OSEE enum types matching [%s] name does not exist", enumTypeName);
}
return itemsFound;
}
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/attribute/utils/AbstractResourceProcessor.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/attribute/utils/AbstractResourceProcessor.java
index f4fc397543..a3a81d6a41 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/attribute/utils/AbstractResourceProcessor.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/attribute/utils/AbstractResourceProcessor.java
@@ -58,8 +58,8 @@ public abstract class AbstractResourceProcessor {
if (code == HttpURLConnection.HTTP_OK) {
dataStore.setContent(outputStream.toByteArray(), "", result.getContentType(), result.getEncoding());
} else {
- throw new OseeDataStoreException(String.format("Error acquiring resource: [%s] - status code: [%s]; %s",
- dataStore.getLocator(), code, new String(outputStream.toByteArray())));
+ throw new OseeDataStoreException("Error acquiring resource: [%s] - status code: [%s]; %s",
+ dataStore.getLocator(), code, new String(outputStream.toByteArray()));
}
} catch (Exception ex) {
OseeExceptions.wrapAndThrow(ex);
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/change/AttributeChange.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/change/AttributeChange.java
index 1dace5cb6d..c98372b2a8 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/change/AttributeChange.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/change/AttributeChange.java
@@ -104,7 +104,8 @@ public final class AttributeChange extends Change {
return attribute;
}
}
- throw new AttributeDoesNotExist(String.format("Could not find Attribute %d on Artifact %d", attrId, getArtId()));
+ throw new AttributeDoesNotExist("Attribute %d could not be found on artifact %d on branch %s", attrId,
+ getArtId(), getBranch().getGuid());
}
@SuppressWarnings("rawtypes")
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/conflict/AttributeConflict.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/conflict/AttributeConflict.java
index 6f4730f5c8..e4c2d8307e 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/conflict/AttributeConflict.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/conflict/AttributeConflict.java
@@ -115,8 +115,8 @@ public class AttributeConflict extends Conflict {
}
}
if (sourceAttribute == null) {
- throw new AttributeDoesNotExist(
- "Attribute " + attrId + " could not be found on Artifact " + getArtId() + " on Branch " + sourceBranch.getId());
+ throw new AttributeDoesNotExist("Attribute %d could not be found on artifact %d on branch %s", attrId,
+ getArtId(), sourceBranch.getGuid());
}
return sourceAttribute;
}
@@ -132,8 +132,8 @@ public class AttributeConflict extends Conflict {
}
}
if (destAttribute == null) {
- throw new AttributeDoesNotExist(
- "Attribute " + attrId + " could not be found on Artifact " + getArtId() + " on Branch " + destBranch.getId());
+ throw new AttributeDoesNotExist("Attribute %d could not be found on artifact %d on branch %s", attrId,
+ getArtId(), destBranch.getGuid());
}
return destAttribute;
}
@@ -147,8 +147,8 @@ public class AttributeConflict extends Conflict {
}
}
if (attribute == null) {
- throw new AttributeDoesNotExist(
- "Attribute " + attrId + " could not be found on Artifact " + artifact.getArtId() + " on Branch " + artifact.getBranch().getId());
+ throw new AttributeDoesNotExist("Attribute %d could not be found on artifact %d on branch %s", attrId,
+ artifact.getArtId(), artifact.getBranch().getGuid());
}
return attribute;
}
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/importing/operations/SourceToRoughArtifactOperation.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/importing/operations/SourceToRoughArtifactOperation.java
index 3576cf02cd..017c5dcec2 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/importing/operations/SourceToRoughArtifactOperation.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/importing/operations/SourceToRoughArtifactOperation.java
@@ -66,7 +66,7 @@ public class SourceToRoughArtifactOperation extends AbstractOperation {
extractArtifacts(monitor, subPercentage, subFiles, collector, directoryArtifact);
}
} else {
- throw new OseeStateException("Source location \"" + file + "\" is not a valid file or directory");
+ throw new OseeStateException("Source location [%s] is not a valid file or directory", file);
}
monitor.worked(workAmount);
}
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/importing/parsers/ExcelArtifactExtractor.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/importing/parsers/ExcelArtifactExtractor.java
index 2e233a284d..f0b8629c1a 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/importing/parsers/ExcelArtifactExtractor.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/importing/parsers/ExcelArtifactExtractor.java
@@ -110,11 +110,10 @@ public class ExcelArtifactExtractor extends AbstractArtifactExtractor {
}
primaryDescriptor = ArtifactTypeManager.getType(sheetName);
if (primaryDescriptor == null) {
- throw new OseeArgumentException("The sheet name: " + sheetName + " is not a valid artifact type name.");
+ throw new OseeArgumentException("The sheet [%s] is not a valid artifact type name.", sheetName);
}
} catch (OseeCoreException ex) {
- throw new IllegalArgumentException("The sheet name: " + sheetName + " is not a valid artifact type name: ",
- ex);
+ throw new IllegalArgumentException("The sheet [%s] is not a valid artifact type name: ", ex);
}
}
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/importing/parsers/WordOutlineExtractor.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/importing/parsers/WordOutlineExtractor.java
index d6fe25272f..79305aefdc 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/importing/parsers/WordOutlineExtractor.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/importing/parsers/WordOutlineExtractor.java
@@ -110,7 +110,7 @@ public class WordOutlineExtractor extends AbstractArtifactExtractor {
}
private void handleFormatError(URI source, String message) throws OseeCoreException {
- throw new OseeStateException(String.format("File format error: %s in file [%s]", message, source.getPath()));
+ throw new OseeStateException("File format error: %s in file [%s]", message, source.getPath());
}
@Override
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/importing/parsers/WordOutlineExtractorDelegate.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/importing/parsers/WordOutlineExtractorDelegate.java
index 741cc94227..451c67b008 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/importing/parsers/WordOutlineExtractorDelegate.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/importing/parsers/WordOutlineExtractorDelegate.java
@@ -163,9 +163,9 @@ public class WordOutlineExtractorDelegate implements IArtifactExtractorDelegate
wordFormattedContent.append(content);
}
} else {
- throw new OseeCoreException(String.format(
+ throw new OseeCoreException(
"%s::processContent() Either passed in content is invalid or *Delegate hasn't been initialized...",
- this.toString()));
+ this.toString());
}
}
@@ -338,9 +338,8 @@ public class WordOutlineExtractorDelegate implements IArtifactExtractorDelegate
return roughArtifact;
} else {
- throw new OseeStateException(String.format(
- "Paragraph %s found more than once following \"%s\" which is a duplicate of %s", outlineNumber,
- previousNamedArtifact.getName(), duplicateArtifact.getName()));
+ throw new OseeStateException("Paragraph %s found more than once following \"%s\" which is a duplicate of %s",
+ outlineNumber, previousNamedArtifact.getName(), duplicateArtifact.getName());
}
}
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/importing/resolvers/NewArtifactImportResolver.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/importing/resolvers/NewArtifactImportResolver.java
index abebe04a0c..7efd1c5e29 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/importing/resolvers/NewArtifactImportResolver.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/importing/resolvers/NewArtifactImportResolver.java
@@ -56,7 +56,7 @@ public class NewArtifactImportResolver implements IArtifactImportResolver {
} else if (kind == RoughArtifactKind.CONTAINER) {
return ArtifactTypeManager.getType(CoreArtifactTypes.Folder);
} else {
- throw new OseeCoreException("Unknown Artifact Kind " + kind);
+ throw new OseeCoreException("Unknown Artifact Kind [%s]", kind);
}
}
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/relation/RelationManager.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/relation/RelationManager.java
index 83e901a00d..47da2f0876 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/relation/RelationManager.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/relation/RelationManager.java
@@ -118,7 +118,8 @@ public class RelationManager {
if (relationLink == null) {
throw new OseeArgumentException(
- "A relation link of type: " + relationType.getName() + "does exist in the cache between a artifact: " + aArtifactId + " and b artifact:" + bArtifactId);
+ "A relation link of type [%s] does exist in the cache between a artifact %d and b artifact %d",
+ relationType, aArtifactId, bArtifactId);
}
return relationLink;
@@ -394,15 +395,14 @@ public class RelationManager {
List<Artifact> artifacts = getRelatedArtifacts(artifact, relationType, relationSide);
if (artifacts.isEmpty()) {
- throw new ArtifactDoesNotExist(String.format("There is no artifact related to %s by a relation of type %s",
- artifact, relationType));
+ throw new ArtifactDoesNotExist("There is no artifact related to [%s] by a relation of type [%s]", artifact,
+ relationType);
}
if (artifacts.size() > 1) {
throw new MultipleArtifactsExist(
- String.format(
- "There are %s artifacts related to \"%s\" by a relation of type \"%s\" on side %s instead of the expected 1.",
- artifacts.size(), artifact, relationType, relationSide.toString()));
+ "There are %s artifacts related to \"%s\" by a relation of type \"%s\" on side %s instead of the expected 1.",
+ artifacts.size(), artifact, relationType, relationSide);
}
return artifacts.get(0);
}
@@ -689,7 +689,7 @@ public class RelationManager {
public static void addRelation(IRelationSorterId sorterId, RelationType relationType, Artifact artifactA, Artifact artifactB, String rationale) throws OseeCoreException {
if (artifactA.equals(artifactB)) {
- throw new OseeArgumentException(String.format("Not valid to relate artifact [%s] to itself", artifactA));
+ throw new OseeArgumentException("Not valid to relate artifact [%s] to itself", artifactA);
}
RelationLink relation =
getLoadedRelation(artifactA, artifactA.getArtId(), artifactB.getArtId(), relationType, true);
@@ -727,8 +727,8 @@ public class RelationManager {
return relation;
}
}
- throw new OseeCoreException(String.format("Unable to find a relation link for type[%s] artA[%s] artB[%s]",
- relationType.getName(), artifactA.getName(), artifactB.getName()));
+ throw new OseeCoreException("Unable to find a relation link for type[%s] artA[%s] artB[%s]",
+ relationType.getName(), artifactA.getName(), artifactB.getName());
}
public static RelationSorterProvider getSorterProvider() {
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/relation/RelationTypeManager.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/relation/RelationTypeManager.java
index e37cc320a9..5a6513cd1d 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/relation/RelationTypeManager.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/relation/RelationTypeManager.java
@@ -81,7 +81,7 @@ public class RelationTypeManager {
public static RelationType getTypeByGuid(String guid) throws OseeCoreException {
RelationType relationType = getCache().getByGuid(guid);
if (relationType == null) {
- throw new OseeTypeDoesNotExist("The relation with type guid [" + guid + "] does not exist");
+ throw new OseeTypeDoesNotExist("The relation with type guid [%s] does not exist", guid);
}
return relationType;
}
@@ -97,7 +97,7 @@ public class RelationTypeManager {
public static RelationType getType(String typeName) throws OseeCoreException {
RelationType relationType = getCache().getUniqueByName(typeName);
if (relationType == null) {
- throw new OseeTypeDoesNotExist("The relation type [" + typeName + "] does not exist");
+ throw new OseeTypeDoesNotExist("The relation type [%s] does not exist", typeName);
}
return relationType;
}
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/relation/order/RelationSorterProvider.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/relation/order/RelationSorterProvider.java
index 4ce07a59dd..e8e6d4fdd0 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/relation/order/RelationSorterProvider.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/relation/order/RelationSorterProvider.java
@@ -59,7 +59,7 @@ public class RelationSorterProvider {
}
IRelationSorter order = orderMap.get(orderGuid);
if (order == null) {
- throw new OseeCoreException(String.format("Unable to locate RelationOrder for guid[%s].", orderGuid));
+ throw new OseeCoreException("Unable to locate RelationOrder for guid[%s].", orderGuid);
}
return order;
}
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/ConflictManagerInternal.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/ConflictManagerInternal.java
index 24d2a1bcf8..92f8ef8a73 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/ConflictManagerInternal.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/revision/ConflictManagerInternal.java
@@ -103,9 +103,9 @@ public class ConflictManagerInternal {
return getConflictsPerBranch(TransactionManager.getTransactionId(commitTransactionId), monitor);
}
if (sourceBranch == null || destinationBranch == null) {
- throw new OseeArgumentException(String.format("Source Branch = %s Destination Branch = %s",
+ throw new OseeArgumentException("Source Branch = %s Destination Branch = %s",
sourceBranch == null ? "NULL" : sourceBranch.getId(),
- destinationBranch == null ? "NULL" : destinationBranch.getId()));
+ destinationBranch == null ? "NULL" : destinationBranch.getId());
}
monitor.beginTask(
String.format("Loading Merge Manager for Branch %d into Branch %d", sourceBranch.getId(),
@@ -382,8 +382,8 @@ public class ConflictManagerInternal {
}
}
if (commonBranch == null) {
- throw new OseeCoreException(String.format("Cannot find a common ancestor for Branch %s and Branch %s",
- sourceBranch.getShortName(), destBranch.getShortName()));
+ throw new OseeCoreException("Cannot find a common ancestor for Branch %s and Branch %s",
+ sourceBranch.getShortName(), destBranch.getShortName());
}
TransactionRecord sourceTransaction = null;
TransactionRecord destTransaction = null;
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/transaction/TransactionManager.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/transaction/TransactionManager.java
index cef3217e87..71c6e330e6 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/transaction/TransactionManager.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/transaction/TransactionManager.java
@@ -159,7 +159,7 @@ public final class TransactionManager {
ConnectionHandler.runPreparedQueryFetchInt(-1, ClientSessionManager.getSql(OseeSql.TX_GET_MAX_AS_LARGEST_TX),
branchId);
if (transactionNumber == -1) {
- throw new TransactionDoesNotExist("No transactions where found in the database for branch: " + branchId);
+ throw new TransactionDoesNotExist("No transactions where found in the database for branch: %d", branchId);
}
return getTransactionId(transactionNumber);
}
@@ -230,10 +230,8 @@ public final class TransactionManager {
int transactionId = chStmt.getInt("transaction_id");
if (chStmt.wasNull()) {
DateFormat dateFormat = DateFormat.getDateTimeInstance(DateFormat.LONG, DateFormat.LONG);
- String message =
- String.format("Cannot find transaction for [%s] - the transation id was null",
- dateFormat.format(maxDateExclusive));
- throw new TransactionDoesNotExist(message);
+ throw new TransactionDoesNotExist("Cannot find transaction for [%s] - the transation id was null",
+ dateFormat.format(maxDateExclusive));
}
txRecord = getTransactionId(transactionId, chStmt);
}
@@ -270,7 +268,7 @@ public final class TransactionManager {
chStmt = ConnectionHandler.getStatement();
chStmt.runPreparedQuery(ClientSessionManager.getSql(OseeSql.TX_GET_ALL_TRANSACTIONS), txId);
if (!chStmt.next()) {
- throw new TransactionDoesNotExist("The transaction id " + txId + " does not exist in the databse.");
+ throw new TransactionDoesNotExist("The transaction id %d does not exist in the databse.", txId);
}
}
TransactionDetailsType txType = TransactionDetailsType.toEnum(chStmt.getInt("tx_type"));
diff --git a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/transaction/TransactionMonitor.java b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/transaction/TransactionMonitor.java
index 06c92dd067..fa619e7b93 100644
--- a/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/transaction/TransactionMonitor.java
+++ b/plugins/org.eclipse.osee.framework.skynet.core/src/org/eclipse/osee/framework/skynet/core/transaction/TransactionMonitor.java
@@ -55,8 +55,8 @@ public class TransactionMonitor {
public synchronized void reportTxStart(final Object transaction, Object key) throws OseeCoreException {
TxOperation currentTx = txMap.get(key);
if (currentTx == null) {
- throw new OseeStateException(
- "reportTxStart called for key: " + key + " but reportTxCreation had not been called.");
+ throw new OseeStateException("reportTxStart called for key: [%s] but reportTxCreation had not been called.",
+ key);
} else if (currentTx.getState() != TxState.CREATED) {
OseeExceptions.wrapAndThrow(currentTx.getError());
}
@@ -64,16 +64,14 @@ public class TransactionMonitor {
if (currentTx.getTransaction().equals(transaction)) {
currentTx.setState(TxState.RUNNING);
} else {
- throw new OseeStateException(
- "reportTxStart called for key: " + key + " but was called for incorrect transaction");
+ throw new OseeStateException("reportTxStart called for key [%s] but was called for incorrect transaction", key);
}
}
public synchronized void reportTxEnd(final Object transaction, Object key) throws OseeCoreException {
TxOperation currentTx = txMap.get(key);
if (currentTx == null) {
- throw new OseeStateException(
- "reportTxEnd called for key: " + key + " but reportTxCreation had not been called.");
+ throw new OseeStateException("reportTxEnd called for key: [%s] but reportTxCreation had not been called.", key);
} else if (currentTx.getState() != TxState.RUNNING) {
// This is a valid case -- can add a log to detect when a reportTxEnd is called before a transaction has a chance to run
}
diff --git a/plugins/org.eclipse.osee.framework.ui.data.model.editor/src/org/eclipse/osee/framework/ui/data/model/editor/model/ArtifactDataType.java b/plugins/org.eclipse.osee.framework.ui.data.model.editor/src/org/eclipse/osee/framework/ui/data/model/editor/model/ArtifactDataType.java
index d26a9de13f..6e635f4eb1 100644
--- a/plugins/org.eclipse.osee.framework.ui.data.model.editor/src/org/eclipse/osee/framework/ui/data/model/editor/model/ArtifactDataType.java
+++ b/plugins/org.eclipse.osee.framework.ui.data.model.editor/src/org/eclipse/osee/framework/ui/data/model/editor/model/ArtifactDataType.java
@@ -146,9 +146,9 @@ public class ArtifactDataType extends DataType {
boolean itemIsAThis = instanceOf(item, this);
String message = "Inheritance constraint violation - [%s] is a [%s]";
if (thisIsAItem) {
- throw new OseeStateException(String.format(message, this, item));
+ throw new OseeStateException(message, this, item);
} else if (itemIsAThis) {
- throw new OseeStateException(String.format(message, item, this));
+ throw new OseeStateException(message, item, this);
}
}
diff --git a/plugins/org.eclipse.osee.framework.ui.plugin/src/org/eclipse/osee/framework/ui/plugin/OseeUiActions.java b/plugins/org.eclipse.osee.framework.ui.plugin/src/org/eclipse/osee/framework/ui/plugin/OseeUiActions.java
index 208610ab27..7d5f04f14b 100644
--- a/plugins/org.eclipse.osee.framework.ui.plugin/src/org/eclipse/osee/framework/ui/plugin/OseeUiActions.java
+++ b/plugins/org.eclipse.osee.framework.ui.plugin/src/org/eclipse/osee/framework/ui/plugin/OseeUiActions.java
@@ -99,13 +99,13 @@ public final class OseeUiActions {
}
if (actionableObject == null) {
- throw new IllegalArgumentException(String.format("actionableObject can not be null"));
+ throw new IllegalArgumentException("actionableObject can not be null");
}
if (!Strings.isValid(editorId)) {
- throw new IllegalArgumentException(String.format("editorId can not be null or empty"));
+ throw new IllegalArgumentException("editorId can not be null or empty");
}
if (actionableItem == null) {
- throw new IllegalArgumentException(String.format("aspect can not be null"));
+ throw new IllegalArgumentException("aspect can not be null");
}
if (toolBar != null) {
@@ -152,7 +152,7 @@ public final class OseeUiActions {
return;
}
if (!Strings.isValid(viewId)) {
- throw new IllegalArgumentException(String.format("viewId can not be null or empty"));
+ throw new IllegalArgumentException("viewId can not be null or empty");
}
if (actionableItem == null) {
throw new IllegalArgumentException("Aspect can not be null.");
diff --git a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/ArtifactExplorer.java b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/ArtifactExplorer.java
index 19386d2a2a..1c2ee4c90a 100644
--- a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/ArtifactExplorer.java
+++ b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/ArtifactExplorer.java
@@ -1393,7 +1393,7 @@ public class ArtifactExplorer extends ViewPart implements IArtifactExplorerEvent
Artifact artifact = artifactData.getArtifact();
Conditions.checkNotNull(artifactData, "artifact");
if (artifact.isDeleted()) {
- throw new OseeStateException("The artifact " + artifact.getName() + " has been deleted.");
+ throw new OseeStateException("The artifact [%s] has been deleted.", artifact.getName());
} else {
if (artifact.isHistorical()) {
artifactData.setArtifact(ArtifactQuery.getArtifactFromId(artifact.getArtId(), artifact.getBranch(),
@@ -1405,8 +1405,8 @@ public class ArtifactExplorer extends ViewPart implements IArtifactExplorerEvent
if (!root.equals(artifactRoot)) {
String artifactRootName = artifactRoot != null ? artifactRoot.getName() : artifact.getName();
- throw new OseeStateException(
- "The artifact " + artifact.getName() + " is rooted on an orphan tree at " + artifactRootName);
+ throw new OseeStateException("The artifact [%s] is rooted on an orphan tree at [%s]",
+ artifact.getName(), artifactRootName);
}
}
}
diff --git a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/XWidgetParser.java b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/XWidgetParser.java
index d0c9cc99c7..b9bda84571 100644
--- a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/XWidgetParser.java
+++ b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/XWidgetParser.java
@@ -138,7 +138,7 @@ public class XWidgetParser {
// do nothing
;
} else {
- throw new OseeArgumentException("Unhandled xOption \"" + xOption + "\"");
+ throw new OseeArgumentException("Unhandled xOption [%s]", xOption);
}
}
doc.appendChild(element);
diff --git a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/artifact/annotation/AnnotationComposite.java b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/artifact/annotation/AnnotationComposite.java
index 19a215d7bb..3426fd84f8 100644
--- a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/artifact/annotation/AnnotationComposite.java
+++ b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/artifact/annotation/AnnotationComposite.java
@@ -48,7 +48,7 @@ public class AnnotationComposite extends Composite {
}
if (notify.getType() == ArtifactAnnotation.Type.None) {
OseeLog.log(SkynetGuiPlugin.class, Level.SEVERE, new OseeStateException(
- "None is an invalid annotation type - " + artifact.getGuid()));
+ "None is an invalid annotation type on artifact [%s]", artifact.getGuid()));
continue;
}
Label iconLabel = toolkit != null ? toolkit.createLabel(this, "") : new Label(this, SWT.NONE);
diff --git a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/blam/DynamicBlamOperation.java b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/blam/DynamicBlamOperation.java
index 433880f35a..c55873b1d8 100644
--- a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/blam/DynamicBlamOperation.java
+++ b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/blam/DynamicBlamOperation.java
@@ -14,8 +14,8 @@ import java.lang.reflect.InvocationTargetException;
import java.lang.reflect.Method;
import java.net.MalformedURLException;
import java.net.URL;
-import java.rmi.activation.ActivationException;
import org.eclipse.core.runtime.CoreException;
+import org.eclipse.osee.framework.core.exception.OseeArgumentException;
import org.eclipse.update.core.IFeature;
import org.eclipse.update.core.ISite;
import org.eclipse.update.core.ISiteFeatureReference;
@@ -38,14 +38,14 @@ public abstract class DynamicBlamOperation {
operationFactory.createInstallOperation(site.getCurrentConfiguredSite(), feature, null, null, null);
}
- public void init() throws ActivationException, IllegalArgumentException, IllegalAccessException, InvocationTargetException, NoSuchMethodException {
+ public void init() throws IllegalArgumentException, IllegalAccessException, InvocationTargetException, NoSuchMethodException, OseeArgumentException {
mainMethod = findMainMethod(getMainMethodName());
String[] parameterNames = getParameterNames();
Class<?>[] parameterTypes = mainMethod.getParameterTypes();
if (parameterNames.length != parameterTypes.length) {
- throw new ActivationException(
- "The method " + getMainMethodName() + " has " + parameterTypes.length + " parameters, but " + parameterNames.length + " parameter names.");
+ throw new OseeArgumentException("The method [%s] has %d parameters, but %d parameter names.",
+ getMainMethodName(), parameterTypes.length, parameterNames.length);
}
parameters = new BlamParameter[parameterTypes.length];
@@ -84,5 +84,4 @@ public abstract class DynamicBlamOperation {
public BlamParameter[] getParameters() {
return parameters;
}
-
-}
+} \ No newline at end of file
diff --git a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/blam/VariableMap.java b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/blam/VariableMap.java
index 976cd63bcc..f5054f1b07 100644
--- a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/blam/VariableMap.java
+++ b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/blam/VariableMap.java
@@ -33,10 +33,10 @@ public class VariableMap {
if (optionArgs[i] instanceof String) {
variableMap.put((String) optionArgs[i], optionArgs[i + 1]);
} else if (optionArgs[i] == null) {
- throw new OseeArgumentException(String.format("The %dth option must not be null", i));
+ throw new OseeArgumentException("The %dth option must not be null", i);
} else {
- throw new OseeArgumentException(String.format("The %dth option must be of type string but is of type %s",
- i, optionArgs[i].getClass().getName()));
+ throw new OseeArgumentException("The %dth option must be of type string but is of type %s", i,
+ optionArgs[i].getClass().getName());
}
}
}
@@ -90,7 +90,7 @@ public class VariableMap {
private <T> T getSingleCollectionValue(Class<T> clazz, String parameterName) throws OseeArgumentException {
Collection<T> objects = getCollection(clazz, parameterName);
if (objects.size() != 1) {
- throw new OseeArgumentException("Require a collection of size 1 not " + objects.size());
+ throw new OseeArgumentException("Require a collection of size 1 not %d", objects.size());
}
return objects.iterator().next();
}
@@ -99,8 +99,7 @@ public class VariableMap {
Object value = variableMap.get(variableName);
if (value != null && !clazz.isInstance(value)) {
- throw new OseeArgumentException(
- "Expecting object of type " + clazz.getName() + " not " + value.getClass().getName());
+ throw new OseeArgumentException("Expecting object of type [%s] not [%s]", clazz, value.getClass());
}
return clazz.cast(value);
}
diff --git a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/blam/operation/ConsolidateRelationsTxOperation.java b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/blam/operation/ConsolidateRelationsTxOperation.java
index f3dee65357..c7da05b1f3 100644
--- a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/blam/operation/ConsolidateRelationsTxOperation.java
+++ b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/blam/operation/ConsolidateRelationsTxOperation.java
@@ -217,7 +217,7 @@ public class ConsolidateRelationsTxOperation extends AbstractDbTxOperation {
netModType = modificationType;
updateAddressing = true;
} else if (!ignoreNetModType(modificationType)) {
- throw new OseeStateException(" modType: " + modificationType + " != " + netModType);
+ throw new OseeStateException(" modType [%s] != [%s]", modificationType, netModType);
}
}
diff --git a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/blam/operation/SetRequirementCategory.java b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/blam/operation/SetRequirementCategory.java
index a5b28191d3..8c58e1e33d 100644
--- a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/blam/operation/SetRequirementCategory.java
+++ b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/blam/operation/SetRequirementCategory.java
@@ -88,7 +88,7 @@ public class SetRequirementCategory extends AbstractBlam {
if (bulkLoad) {
requirement = reqs.get(canonicalRequirementName);
if (requirement == null) {
- throw new ArtifactDoesNotExist("cant' find " + canonicalRequirementName);
+ throw new ArtifactDoesNotExist("No requirement with name [%s] found.", canonicalRequirementName);
}
} else {
try {
diff --git a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/FileSystemRenderer.java b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/FileSystemRenderer.java
index d96a107e8f..284af75a91 100644
--- a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/FileSystemRenderer.java
+++ b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/FileSystemRenderer.java
@@ -196,7 +196,8 @@ public abstract class FileSystemRenderer extends DefaultArtifactRenderer {
page.openEditor(new FileEditorInput(file), editorDescriptor.getId());
} catch (PartInitException ex1) {
throw new OseeArgumentException(
- "No program associated with the extension " + file.getFileExtension() + " found on your local machine.");
+ "No program associated with the extension [%s] found on your local machine.",
+ file.getFileExtension());
}
}
}
diff --git a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/NativeRenderer.java b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/NativeRenderer.java
index 703947fe84..c96879d2e0 100644
--- a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/NativeRenderer.java
+++ b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/NativeRenderer.java
@@ -76,8 +76,8 @@ public class NativeRenderer extends FileSystemRenderer {
String extension = getAssociatedExtension(artifact);
Program program = Program.findProgram(extension);
if (program == null) {
- throw new OseeArgumentException(
- "No program associated with the extension " + extension + " found on your local machine.");
+ throw new OseeArgumentException("No program associated with the extension [%s] found on your local machine.",
+ extension);
}
return program;
}
diff --git a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/RendererManager.java b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/RendererManager.java
index fce4f07741..582cee1214 100644
--- a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/RendererManager.java
+++ b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/RendererManager.java
@@ -110,8 +110,8 @@ public final class RendererManager {
if (bestRenderer instanceof FileSystemRenderer) {
return (FileSystemRenderer) bestRenderer;
}
- throw new OseeArgumentException(
- "No FileRenderer found for " + artifact + " of type " + artifact.getArtifactTypeName());
+ throw new OseeArgumentException("No FileRenderer found for [%s] of type [%s]", artifact,
+ artifact.getArtifactType());
}
public static IRenderer getBestRenderer(PresentationType presentationType, Artifact artifact, VariableMap options) throws OseeCoreException {
@@ -135,7 +135,7 @@ public final class RendererManager {
}
}
if (bestRendererPrototype == null) {
- throw new OseeStateException(String.format("No renderer configured for %s of %s", presentationType, artifact));
+ throw new OseeStateException("No renderer configured for %s of %s", presentationType, artifact);
}
return bestRendererPrototype;
}
diff --git a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/RenderingUtil.java b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/RenderingUtil.java
index 8e0fcbaa7b..9e2769dec0 100644
--- a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/RenderingUtil.java
+++ b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/RenderingUtil.java
@@ -147,7 +147,7 @@ public final class RenderingUtil {
toReturn = mergeEditFolder;
break;
default:
- throw new OseeArgumentException(String.format("Unexpected presentation type: %s", presentationType));
+ throw new OseeArgumentException("Unexpected presentation type: %s", presentationType);
}
return toReturn;
}
diff --git a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/UpdateArtifactOperation.java b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/UpdateArtifactOperation.java
index 09d0df5103..c130bf956c 100644
--- a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/UpdateArtifactOperation.java
+++ b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/UpdateArtifactOperation.java
@@ -221,8 +221,8 @@ public class UpdateArtifactOperation extends AbstractOperation {
}
} finally {
if (!deletedGuids.isEmpty()) {
- throw new OseeStateException("The following deleted artifacts could not be saved: " + Collections.toString(
- ",", deletedGuids));
+ throw new OseeStateException("The following deleted artifacts could not be saved [%s]",
+ Collections.toString(",", deletedGuids));
}
}
}
@@ -241,7 +241,7 @@ public class UpdateArtifactOperation extends AbstractOperation {
return attributes.item(i).getNodeValue();
}
}
- throw new OseeArgumentException("didn't find the guid attribure in element: " + artifactElement);
+ throw new OseeArgumentException("didn't find the guid attribure in element [%s]", artifactElement);
}
} \ No newline at end of file
diff --git a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/WholeWordRenderer.java b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/WholeWordRenderer.java
index 6aff10ce56..e8d868753c 100644
--- a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/WholeWordRenderer.java
+++ b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/WholeWordRenderer.java
@@ -78,7 +78,8 @@ public class WholeWordRenderer extends WordRenderer {
String content = artifact.getOrInitializeSoleAttributeValue(CoreAttributeTypes.WholeWordContent);
if (presentationType == PresentationType.DIFF && WordAnnotationHandler.containsWordAnnotations(content)) {
throw new OseeStateException(
- "Trying to diff the " + artifact.getName() + " artifact on the " + artifact.getBranch().getShortName() + " branch, which has tracked changes turned on. All tracked changes must be removed before the artifacts can be compared.");
+ "Trying to diff the [%s] artifact on the [%s] branch, which has tracked changes turned on. All tracked changes must be removed before the artifacts can be compared.",
+ artifact.getName(), artifact.getBranch().getShortName());
}
LinkType linkType = LinkType.OSEE_SERVER_LINK;
diff --git a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/WordmlPicture.java b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/WordmlPicture.java
index f2b25c3a51..c79b4f95b6 100644
--- a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/WordmlPicture.java
+++ b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/WordmlPicture.java
@@ -12,6 +12,7 @@ package org.eclipse.osee.framework.ui.skynet.render;
import org.eclipse.core.runtime.Platform;
import org.eclipse.osee.framework.core.exception.OseeCoreException;
+import org.eclipse.osee.framework.skynet.core.artifact.Artifact;
import org.eclipse.osee.framework.skynet.core.artifact.Attribute;
/**
@@ -33,6 +34,7 @@ public class WordmlPicture {
}
private void findBinaryData(String document) throws OseeCoreException {
+ Artifact artifact = attribute.getArtifact();
if (pictureDefinition.contains("<v:textbox ") || pictureDefinition.contains("<v:rect ") || pictureDefinition.contains("<v:line ")) {
//ignore this case
} else if (pictureDefinition.contains("<w:binData")) {
@@ -47,7 +49,8 @@ public class WordmlPicture {
System.out.println(pictureDefinition);
}
throw new OseeCoreException(
- "This document is missing Image Data. The Image can not be checked for modifications Artifact =>" + attribute.getArtifact().getSafeName() + " " + attribute.getArtifact().getArtId());
+ "This document is missing Image Data. The Image can not be checked for modifications. Artifact [%s] with id [%s]",
+ artifact, artifact.getGuid());
}
binaryData =
document.substring(document.indexOf(">", dataIndex) + 1,
@@ -58,7 +61,8 @@ public class WordmlPicture {
System.out.println(pictureDefinition);
}
throw new OseeCoreException(
- "This document contains undefined picture data. Please report details to OSEE development team. Artifact=> " + attribute.getArtifact().getSafeName() + " " + attribute.getArtifact().getArtId());
+ "This document contains undefined picture data. Please report details to OSEE development team. Artifact [%s] with id [%s]",
+ artifact, artifact.getGuid());
}
}
}
diff --git a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/word/WordTemplateFileDiffer.java b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/word/WordTemplateFileDiffer.java
index 159a0923b1..96be88c20d 100644
--- a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/word/WordTemplateFileDiffer.java
+++ b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/word/WordTemplateFileDiffer.java
@@ -61,8 +61,8 @@ public class WordTemplateFileDiffer {
Branch startBranch = variableMap.getBranch("compareBranch");
if (endBranch == null || startBranch == null && !variableMap.getBoolean("Diff from Baseline")) {
- throw new OseeCoreException(
- "Must Select a " + endBranch == null ? "Branch" : "Date" + " to diff against when publishing as Diff");
+ throw new OseeCoreException("Must Select a %s to diff against when publishing as Diff",
+ endBranch == null ? "Branch" : "Date");
}
TransactionRecord startTransaction;
boolean isDiffFromBaseline = false;//variableMap.getBoolean("Diff from Baseline");
diff --git a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/word/WordTemplateProcessor.java b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/word/WordTemplateProcessor.java
index c425810f17..8dcd6aeb54 100644
--- a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/word/WordTemplateProcessor.java
+++ b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/render/word/WordTemplateProcessor.java
@@ -12,7 +12,6 @@
package org.eclipse.osee.framework.ui.skynet.render.word;
import static org.eclipse.osee.framework.core.enums.DeletionFlag.EXCLUDE_DELETED;
-import java.io.IOException;
import java.io.InputStream;
import java.nio.charset.CharacterCodingException;
import java.util.ArrayList;
@@ -185,7 +184,7 @@ public class WordTemplateProcessor {
OseeExceptions.wrapAndThrow(ex);
}
} else {
- throw new OseeArgumentException("Invalid input: " + elementType);
+ throw new OseeArgumentException("Invalid input [%s]", elementType);
}
}
// Write out the last of the template
diff --git a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/results/ResultsEditorConverter.java b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/results/ResultsEditorConverter.java
index ae3ed0dc59..cac8cc03c2 100644
--- a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/results/ResultsEditorConverter.java
+++ b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/results/ResultsEditorConverter.java
@@ -20,6 +20,7 @@ import org.eclipse.nebula.widgets.xviewer.XViewerColumn;
import org.eclipse.osee.framework.core.exception.OseeArgumentException;
import org.eclipse.osee.framework.core.exception.OseeCoreException;
import org.eclipse.osee.framework.core.exception.OseeExceptions;
+import org.eclipse.osee.framework.core.exception.OseeStateException;
import org.eclipse.osee.framework.core.util.TableWriterAdaptor;
import org.eclipse.osee.framework.jdk.core.util.AHTML;
import org.eclipse.osee.framework.jdk.core.util.io.xml.ExcelXmlWriter;
@@ -52,14 +53,14 @@ public class ResultsEditorConverter {
}
}
if (toReturn == null) {
- throw new OseeArgumentException(String.format("Conversion to [%s] is not supported", type));
+ throw new OseeArgumentException("Conversion to [%s] is not supported", type);
}
return toReturn;
}
private void checkForNull(String param, Object object) throws OseeArgumentException {
if (object == null) {
- throw new OseeArgumentException(String.format("[%s] cannot be null", param));
+ throw new OseeArgumentException("[%s] cannot be null", param);
}
}
@@ -153,8 +154,7 @@ public class ResultsEditorConverter {
String htmlString = ((IResultsEditorHtmlTab) rawTab).getReportHtml();
writer.write(htmlString);
} else {
- throw new UnsupportedOperationException(String.format("%s to type %s is not supported",
- rawTab.getClass(), getType()));
+ throw new OseeStateException("%s to type %s is not supported", rawTab.getClass(), getType());
}
writer.write("</div>\n");
}
@@ -184,8 +184,7 @@ public class ResultsEditorConverter {
@Override
public void canConvert(IResultsEditorTab tab) throws OseeCoreException {
if (!(tab instanceof IResultsEditorTableTab)) {
- throw new OseeArgumentException(String.format("%s to type %s is not supported", tab.getClass(),
- getType().toUpperCase()));
+ throw new OseeArgumentException("%s to type %s is not supported", tab.getClass(), getType().toUpperCase());
}
}
@@ -205,8 +204,7 @@ public class ResultsEditorConverter {
}
sheetWriter.endSheet();
} else {
- throw new UnsupportedOperationException(String.format("%s to type %s is not supported",
- rawTab.getClass(), getType()));
+ throw new OseeStateException("%s to type %s is not supported", rawTab.getClass(), getType());
}
}
sheetWriter.endWorkbook();
@@ -234,8 +232,7 @@ public class ResultsEditorConverter {
@Override
public void canConvert(IResultsEditorTab tab) throws OseeCoreException {
if (!(tab instanceof IResultsEditorTableTab)) {
- throw new OseeArgumentException(String.format("%s to type %s is not supported", tab.getClass(),
- getType().toUpperCase()));
+ throw new OseeArgumentException("%s to type %s is not supported", tab.getClass(), getType().toUpperCase());
}
}
@@ -262,8 +259,7 @@ public class ResultsEditorConverter {
}
writerAdaptor.writeDocument();
} else {
- throw new UnsupportedOperationException(String.format("%s to type %s is not supported",
- rawTab.getClass(), getType()));
+ throw new OseeStateException("%s to type %s is not supported", rawTab.getClass(), getType());
}
}
writerAdaptor.close();
diff --git a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/templates/ArtifactTemplateProvider.java b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/templates/ArtifactTemplateProvider.java
index abdf131a47..73ba3b600c 100644
--- a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/templates/ArtifactTemplateProvider.java
+++ b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/templates/ArtifactTemplateProvider.java
@@ -89,8 +89,8 @@ public class ArtifactTemplateProvider implements ITemplateProvider {
} else {
return template;
}
- throw new OseeArgumentException(String.format("Unable to find a valid template match for [%s, %s, %s, %s].",
- renderer.toString(), artifact.toString(), presentationType, option));
+ throw new OseeArgumentException("Unable to find a valid template match for [%s, %s, %s, %s].",
+ renderer.toString(), artifact.toString(), presentationType, option);
}
private Artifact getArtifactFromOptionName(String name) throws OseeCoreException {
@@ -110,8 +110,8 @@ public class ArtifactTemplateProvider implements ITemplateProvider {
private List<String> getPossibleTemplateNamesOrderedBySpecialization(IRenderer renderer, Artifact artifact, String presentationType, String option) throws OseeArgumentException {
if (renderer == null || presentationType == null) {
- throw new OseeArgumentException(String.format("Invalid renderer[%s] or presentationType[%s]",
- renderer.toString(), presentationType.toString()));
+ throw new OseeArgumentException("Invalid renderer[%s] or presentationType[%s]",
+ renderer.toString(), presentationType.toString());
}
List<String> list = new ArrayList<String>();
diff --git a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/widgets/XSelectFromDialog.java b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/widgets/XSelectFromDialog.java
index 50bef608ca..baf3552cf2 100644
--- a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/widgets/XSelectFromDialog.java
+++ b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/widgets/XSelectFromDialog.java
@@ -65,8 +65,8 @@ public abstract class XSelectFromDialog<T> extends XText {
}
if (maxSelectionRequired < minSelectionRequired) {
- throw new OseeArgumentException(String.format("Invalid required number of selections [%s] < [%s]",
- maxSelectionRequired, minSelectionRequired));
+ throw new OseeArgumentException("Invalid required number of selections [%s] < [%s]",
+ maxSelectionRequired, minSelectionRequired);
}
this.minSelectionRequired = minSelectionRequired;
this.maxSelectionRequired = maxSelectionRequired;
diff --git a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/widgets/workflow/WorkFlowDefinition.java b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/widgets/workflow/WorkFlowDefinition.java
index 97fae20e99..d99a499f81 100644
--- a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/widgets/workflow/WorkFlowDefinition.java
+++ b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/widgets/workflow/WorkFlowDefinition.java
@@ -241,11 +241,9 @@ public class WorkFlowDefinition extends WorkItemWithChildrenDefinition {
for (String transition : artifact.getAttributesToStringList(CoreAttributeTypes.WorkTransition)) {
String[] strs = transition.split(";");
if (strs.length != 3) {
- OseeLog.log(
- SkynetGuiPlugin.class,
- OseeLevel.SEVERE_POPUP,
- new OseeStateException(
- "Transition attribute from artifact " + artifact.getGuid() + " is invalid. Must be <fromState>;<transitionType>;<toState>"));
+ OseeLog.log(SkynetGuiPlugin.class, OseeLevel.SEVERE_POPUP, new OseeStateException(
+ "Transition attribute from artifact [%s] is invalid. Must be <fromState>;<transitionType>;<toState>",
+ artifact.getGuid()));
continue;
}
TransitionType transType = TransitionType.valueOf(strs[1]);
diff --git a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/widgets/workflow/WorkFlowDefinitionFactory.java b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/widgets/workflow/WorkFlowDefinitionFactory.java
index 83df8b6cb8..ac4aeae8e5 100644
--- a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/widgets/workflow/WorkFlowDefinitionFactory.java
+++ b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/widgets/workflow/WorkFlowDefinitionFactory.java
@@ -27,7 +27,6 @@ public class WorkFlowDefinitionFactory {
return workFlowDefinition;
}
}
- throw new OseeArgumentException(
- "No WorkFlowDefinition found for artifact " + artifact.getArtifactTypeName() + " - " + artifact.getGuid());
+ throw new OseeArgumentException("No WorkFlowDefinition found for artifact [%s]", artifact.getGuid());
}
}
diff --git a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/widgets/workflow/WorkItemDefinitionFactory.java b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/widgets/workflow/WorkItemDefinitionFactory.java
index 00ba5e4da2..fb437f5868 100644
--- a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/widgets/workflow/WorkItemDefinitionFactory.java
+++ b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/widgets/workflow/WorkItemDefinitionFactory.java
@@ -132,8 +132,8 @@ public class WorkItemDefinitionFactory {
throw new OseeArgumentException("Item Id can't be null");
}
if (writeType == WriteType.New && itemIdToDefinition.containsKey(workItemDefinition.getId())) {
- throw new OseeArgumentException(
- "Item Id must be unique. Already work item with id \"" + workItemDefinition.getId() + "\"");
+ throw new OseeArgumentException("Item Id must be unique. Already work item with id [%s]",
+ workItemDefinition.getId());
}
itemIdToDefinition.put(workItemDefinition.getId(), workItemDefinition);
}
diff --git a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/widgets/workflow/XWidgetFactory.java b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/widgets/workflow/XWidgetFactory.java
index f3e79f331e..f60234b3ad 100644
--- a/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/widgets/workflow/XWidgetFactory.java
+++ b/plugins/org.eclipse.osee.framework.ui.skynet/src/org/eclipse/osee/framework/ui/skynet/widgets/workflow/XWidgetFactory.java
@@ -199,8 +199,7 @@ public final class XWidgetFactory {
}
xWidget = combo;
} else {
- throw new OseeArgumentException(
- "Invalid XComboDam. " + "Must be \"XComboDam(option1,option2,option3)\"");
+ throw new OseeArgumentException("Invalid XComboDam. Must be \"XComboDam(option1,option2,option3)\"");
}
}
} else if (xWidgetName.startsWith("XSelectFromMultiChoiceDam")) {
@@ -213,7 +212,7 @@ public final class XWidgetFactory {
xWidget = widget;
} else {
throw new OseeArgumentException(
- "Invalid XSelectFromMultiChoiceDam. " + "Must be \"XSelectFromMultiChoiceDam(option1,option2,option3)\"");
+ "Invalid XSelectFromMultiChoiceDam. Must be \"XSelectFromMultiChoiceDam(option1,option2,option3)\"");
}
}
} else if (xWidgetName.startsWith("XStackedDam")) {
@@ -264,7 +263,7 @@ public final class XWidgetFactory {
}
xWidget = combo;
} else {
- throw new OseeArgumentException("Invalid XCombo. " + "Must be \"XCombo(option1,option2,option3)\"");
+ throw new OseeArgumentException("Invalid XCombo. Must be \"XCombo(option1,option2,option3)\"");
}
} else if (xWidgetName.startsWith("XListDam")) {
if (xWidgetLayoutData.getDynamicXWidgetLayout() != null) {
@@ -275,7 +274,7 @@ public final class XWidgetFactory {
list.add(values);
xWidget = list;
} else {
- throw new OseeArgumentException("Invalid XList. " + "Must be \"XList(option1,option2,option3)\"");
+ throw new OseeArgumentException("Invalid XList. Must be \"XList(option1,option2,option3)\"");
}
}
} else if (xWidgetName.equals("XHyperlabelMemberSelDam")) {
@@ -305,7 +304,7 @@ public final class XWidgetFactory {
list.setSelected(Arrays.asList(defaultValue.split(",")));
}
} else {
- throw new OseeArgumentException("Invalid XList. " + "Must be \"XList(option1,option2,option3)\"");
+ throw new OseeArgumentException("Invalid XList. Must be \"XList(option1,option2,option3)\"");
}
} else if (xWidgetName.startsWith("XArtifactList")) {
XArtifactList artifactList = new XArtifactList(name);
diff --git a/plugins/org.eclipse.osee.ote.define/src/org/eclipse/osee/ote/define/artifacts/TestRunOperator.java b/plugins/org.eclipse.osee.ote.define/src/org/eclipse/osee/ote/define/artifacts/TestRunOperator.java
index fe47235ac3..041886ea08 100644
--- a/plugins/org.eclipse.osee.ote.define/src/org/eclipse/osee/ote/define/artifacts/TestRunOperator.java
+++ b/plugins/org.eclipse.osee.ote.define/src/org/eclipse/osee/ote/define/artifacts/TestRunOperator.java
@@ -58,8 +58,8 @@ public class TestRunOperator {
private void checkForType(Artifact artifact) throws OseeArgumentException {
try {
if (!artifact.isOfType(CoreArtifactTypes.TestRun)) {
- throw new OseeArgumentException(String.format("Unable to operate on type [%s]. Only [%s] allowed.",
- artifact.getArtifactTypeName(), CoreArtifactTypes.TestRun));
+ throw new OseeArgumentException("Unable to operate on type [%s]. Only [%s] allowed.",
+ artifact.getArtifactTypeName(), CoreArtifactTypes.TestRun);
}
} catch (OseeCoreException e) {
// TODO Auto-generated catch block
diff --git a/plugins/org.eclipse.osee.ote.define/src/org/eclipse/osee/ote/define/operations/ImportOutfileOperation.java b/plugins/org.eclipse.osee.ote.define/src/org/eclipse/osee/ote/define/operations/ImportOutfileOperation.java
index 586ea07cf0..2e5e1347fd 100644
--- a/plugins/org.eclipse.osee.ote.define/src/org/eclipse/osee/ote/define/operations/ImportOutfileOperation.java
+++ b/plugins/org.eclipse.osee.ote.define/src/org/eclipse/osee/ote/define/operations/ImportOutfileOperation.java
@@ -49,7 +49,7 @@ public class ImportOutfileOperation {
private void checkSuccessful(IStatus status) throws OseeStateException {
if (status.equals(Status.OK_STATUS) != true && status.equals(IStatus.OK) != true) {
- throw new OseeStateException(String.format("Error detected: %s", status.getMessage()));
+ throw new OseeStateException("Error detected: %s", status.getMessage());
}
}
@@ -93,7 +93,7 @@ public class ImportOutfileOperation {
Artifact[] notAllowed = job.getCommitNotAllowed();
if (notAllowed.length > 0) {
- throw new IllegalArgumentException(String.format("Some items are not commitable. [%s]", toString(notAllowed)));
+ throw new OseeArgumentException("Some items are not commitable. [%s]", toString(notAllowed));
}
commitSelectedArtifacts(monitor, commitComment, job.getCommitAllowed());
}
diff --git a/plugins/org.eclipse.osee.ote.define/src/org/eclipse/osee/ote/define/utilities/OutfileParserExtensionManager.java b/plugins/org.eclipse.osee.ote.define/src/org/eclipse/osee/ote/define/utilities/OutfileParserExtensionManager.java
index 0c34adcac4..e52bc0507b 100644
--- a/plugins/org.eclipse.osee.ote.define/src/org/eclipse/osee/ote/define/utilities/OutfileParserExtensionManager.java
+++ b/plugins/org.eclipse.osee.ote.define/src/org/eclipse/osee/ote/define/utilities/OutfileParserExtensionManager.java
@@ -71,8 +71,7 @@ public class OutfileParserExtensionManager {
}
}
if (toReturn == null) {
- throw new OseeStateException(String.format("Unsupported outfile type [%s] no valid outfile parser found",
- fileToImport));
+ throw new OseeStateException("Unsupported outfile type [%s] no valid outfile parser found", fileToImport);
}
return toReturn;
}
diff --git a/plugins/org.eclipse.osee.ote.message/META-INF/MANIFEST.MF b/plugins/org.eclipse.osee.ote.message/META-INF/MANIFEST.MF
index a2fc8baae6..5ad92bc19d 100644
--- a/plugins/org.eclipse.osee.ote.message/META-INF/MANIFEST.MF
+++ b/plugins/org.eclipse.osee.ote.message/META-INF/MANIFEST.MF
@@ -30,3 +30,5 @@ Require-Bundle: org.eclipse.osee.ote.core,
Bundle-ActivationPolicy: lazy
Bundle-RequiredExecutionEnvironment: JavaSE-1.6
Bundle-Activator: org.eclipse.osee.ote.message.internal.Activator
+Import-Package: org.eclipse.core.runtime,
+ org.eclipse.osee.framework.core.exception
diff --git a/plugins/org.eclipse.osee.ote.message/src/org/eclipse/osee/ote/message/tool/AbstractMessageToolService.java b/plugins/org.eclipse.osee.ote.message/src/org/eclipse/osee/ote/message/tool/AbstractMessageToolService.java
index a39d7e4d96..881ca5ce97 100644
--- a/plugins/org.eclipse.osee.ote.message/src/org/eclipse/osee/ote/message/tool/AbstractMessageToolService.java
+++ b/plugins/org.eclipse.osee.ote.message/src/org/eclipse/osee/ote/message/tool/AbstractMessageToolService.java
@@ -770,9 +770,6 @@ public class AbstractMessageToolService implements IRemoteMessageService {
} catch (IOException e) {
OseeLog.log(MessageSystemTestEnvironment.class, Level.INFO, "Exception while stopping message recording", e);
throw new RemoteException("could not stop recorder", e);
- } catch (InterruptedException e) {
- OseeLog.log(MessageSystemTestEnvironment.class, Level.INFO, "Exception while stopping message recording", e);
- throw new RemoteException("could not stop recorder", e);
}
try {
recorderOutputChannel.disconnect();
@@ -819,8 +816,6 @@ public class AbstractMessageToolService implements IRemoteMessageService {
recorder.stopRecording(false);
} catch (IOException e) {
OseeLog.log(MessageSystemTestEnvironment.class, Level.SEVERE, "failed to stop recording", e);
- } catch (InterruptedException e) {
- OseeLog.log(MessageSystemTestEnvironment.class, Level.SEVERE, "failed to stop recording", e);
}
}
diff --git a/plugins/org.eclipse.osee.ote.message/src/org/eclipse/osee/ote/message/tool/rec/IMessageEntryFactory.java b/plugins/org.eclipse.osee.ote.message/src/org/eclipse/osee/ote/message/tool/rec/IMessageEntryFactory.java
index a96311b8d5..fe099743da 100644
--- a/plugins/org.eclipse.osee.ote.message/src/org/eclipse/osee/ote/message/tool/rec/IMessageEntryFactory.java
+++ b/plugins/org.eclipse.osee.ote.message/src/org/eclipse/osee/ote/message/tool/rec/IMessageEntryFactory.java
@@ -10,10 +10,11 @@
*******************************************************************************/
package org.eclipse.osee.ote.message.tool.rec;
+import org.eclipse.osee.framework.core.exception.OseeCoreException;
import org.eclipse.osee.ote.message.Message;
import org.eclipse.osee.ote.message.tool.rec.entry.IMessageEntry;
public interface IMessageEntryFactory<T extends Message<?, ?, T>> {
- public IMessageEntry createMessageEntry(MessageRecordConfig config, MessageRecorder recorder);
+ public IMessageEntry createMessageEntry(MessageRecordConfig config, MessageRecorder recorder) throws OseeCoreException;
}
diff --git a/plugins/org.eclipse.osee.ote.message/src/org/eclipse/osee/ote/message/tool/rec/MessageRecorder.java b/plugins/org.eclipse.osee.ote.message/src/org/eclipse/osee/ote/message/tool/rec/MessageRecorder.java
index dd339963b2..32056bbbba 100644
--- a/plugins/org.eclipse.osee.ote.message/src/org/eclipse/osee/ote/message/tool/rec/MessageRecorder.java
+++ b/plugins/org.eclipse.osee.ote.message/src/org/eclipse/osee/ote/message/tool/rec/MessageRecorder.java
@@ -22,6 +22,7 @@ import java.util.concurrent.Future;
import java.util.concurrent.locks.Lock;
import java.util.concurrent.locks.ReentrantLock;
import java.util.logging.Level;
+import org.eclipse.osee.framework.core.exception.OseeCoreException;
import org.eclipse.osee.framework.logging.OseeLog;
import org.eclipse.osee.ote.core.environment.TestEnvironmentInterface;
import org.eclipse.osee.ote.message.MessageSystemTestEnvironment;
@@ -54,7 +55,7 @@ public class MessageRecorder {
}
}
- public void startRecording(Collection<MessageRecordConfig> list, WritableByteChannel channel) throws InterruptedException {
+ public void startRecording(Collection<MessageRecordConfig> list, WritableByteChannel channel) throws OseeCoreException {
if (list == null) {
throw new IllegalArgumentException("list cannot be null");
}
@@ -100,7 +101,7 @@ public class MessageRecorder {
return env.getEnvTime();
}
- public void stopRecording(boolean closeOutputChannel) throws IOException, InterruptedException {
+ public void stopRecording(boolean closeOutputChannel) throws IOException {
OseeLog.log(MessageSystemTestEnvironment.class, Level.INFO, "stopping message recorder...");
isRecording = false;
recLock.lock();
diff --git a/plugins/org.eclipse.osee.ote.message/src/org/eclipse/osee/ote/message/tool/rec/entry/MessageRecEntry.java b/plugins/org.eclipse.osee.ote.message/src/org/eclipse/osee/ote/message/tool/rec/entry/MessageRecEntry.java
index 34ca9c6ad6..595dbbaab8 100644
--- a/plugins/org.eclipse.osee.ote.message/src/org/eclipse/osee/ote/message/tool/rec/entry/MessageRecEntry.java
+++ b/plugins/org.eclipse.osee.ote.message/src/org/eclipse/osee/ote/message/tool/rec/entry/MessageRecEntry.java
@@ -18,6 +18,7 @@ import java.util.Comparator;
import java.util.HashMap;
import java.util.concurrent.ArrayBlockingQueue;
import java.util.logging.Level;
+import org.eclipse.osee.framework.core.exception.OseeArgumentException;
import org.eclipse.osee.framework.jdk.core.util.benchmark.Benchmark;
import org.eclipse.osee.framework.logging.OseeLog;
import org.eclipse.osee.ote.message.IMessageHeader;
@@ -59,7 +60,7 @@ public class MessageRecEntry<T extends Message<?, ?, T>> implements IMessageEntr
private boolean bodyDump;
private boolean headerDump;
- public MessageRecEntry(T msg, DataType type, boolean headerDump, Element[] hdrElements, boolean bodyDump, Element[] bdyElements, MessageRecorder recorder) {
+ public MessageRecEntry(T msg, DataType type, boolean headerDump, Element[] hdrElements, boolean bodyDump, Element[] bdyElements, MessageRecorder recorder) throws OseeArgumentException {
this.msg = msg;
this.type = type;
this.recorder = recorder;
@@ -85,8 +86,7 @@ public class MessageRecEntry<T extends Message<?, ?, T>> implements IMessageEntr
i = 0;
for (Element element : bdyElements) {
if (element.getMsgData().getType() != type) {
- throw new IllegalArgumentException(String.format("all elements(%s) must have a mem type of %s",
- element.getName(), type.toString()));
+ throw new OseeArgumentException("all elements(%s) must have a mem type of %s", element.getName(), type);
}
bodyEntries[i] = ElementEntryFactory.createEntry(element);
i++;
diff --git a/plugins/org.eclipse.osee.ote.ui.define/src/org/eclipse/osee/ote/ui/define/dialogs/ReportsDialog.java b/plugins/org.eclipse.osee.ote.ui.define/src/org/eclipse/osee/ote/ui/define/dialogs/ReportsDialog.java
index 66e5a9bd25..187887f140 100644
--- a/plugins/org.eclipse.osee.ote.ui.define/src/org/eclipse/osee/ote/ui/define/dialogs/ReportsDialog.java
+++ b/plugins/org.eclipse.osee.ote.ui.define/src/org/eclipse/osee/ote/ui/define/dialogs/ReportsDialog.java
@@ -34,7 +34,7 @@ import org.eclipse.jface.viewers.LabelProvider;
import org.eclipse.jface.viewers.SelectionChangedEvent;
import org.eclipse.jface.viewers.Viewer;
import org.eclipse.jface.viewers.ViewerSorter;
-import org.eclipse.osee.framework.core.exception.OseeStateException;
+import org.eclipse.osee.framework.core.exception.OseeCoreException;
import org.eclipse.osee.framework.jdk.core.type.Pair;
import org.eclipse.osee.framework.jdk.core.util.Strings;
import org.eclipse.osee.framework.logging.OseeLog;
@@ -415,7 +415,7 @@ public class ReportsDialog extends TitleAreaDialog {
});
}
- private void generatePreview(final OutputFormat outputFormat, final String reportId, final ITestRunReport report) throws URISyntaxException, OseeStateException {
+ private void generatePreview(final OutputFormat outputFormat, final String reportId, final ITestRunReport report) throws URISyntaxException, OseeCoreException {
String urlRequest = HttpReportRequest.getUrl(reportId, outputFormat.name(), "local", getPreviewSize());
String fileName = OutputFactory.getOutputFilename(outputFormat, reportId);
switch (outputFormat) {
diff --git a/plugins/org.eclipse.osee.ote.ui.define/src/org/eclipse/osee/ote/ui/define/reports/output/OutputFactory.java b/plugins/org.eclipse.osee.ote.ui.define/src/org/eclipse/osee/ote/ui/define/reports/output/OutputFactory.java
index 4b8dfd3251..72da59d819 100644
--- a/plugins/org.eclipse.osee.ote.ui.define/src/org/eclipse/osee/ote/ui/define/reports/output/OutputFactory.java
+++ b/plugins/org.eclipse.osee.ote.ui.define/src/org/eclipse/osee/ote/ui/define/reports/output/OutputFactory.java
@@ -11,6 +11,7 @@
package org.eclipse.osee.ote.ui.define.reports.output;
import java.util.Date;
+import org.eclipse.osee.framework.core.exception.OseeArgumentException;
/**
* @author Roberto E. Escobar
@@ -21,7 +22,7 @@ public class OutputFactory {
private OutputFactory() {
}
- public static IReportWriter getReportWriter(OutputFormat format) {
+ public static IReportWriter getReportWriter(OutputFormat format) throws OseeArgumentException {
IReportWriter toReturn = null;
switch (format) {
case EXCEL:
@@ -33,12 +34,12 @@ public class OutputFactory {
toReturn = new ReportWriter(format.name());
break;
default:
- throw new IllegalArgumentException(String.format("Unsupported format [%s]", format));
+ throw new OseeArgumentException("Unsupported format [%s]", format);
}
return toReturn;
}
- public static String getOutputFilename(OutputFormat format, String reportId) {
+ public static String getOutputFilename(OutputFormat format, String reportId) throws OseeArgumentException {
String extension = "";
switch (format) {
case HTML:
@@ -54,7 +55,7 @@ public class OutputFactory {
extension = "rtf";
break;
default:
- throw new IllegalArgumentException(String.format("Unsupported format [%s]", format));
+ throw new OseeArgumentException("Unsupported format [%s]", format);
}
StringBuilder builder = new StringBuilder(reportId);
builder.append(SEPARATOR);
@@ -64,7 +65,7 @@ public class OutputFactory {
return builder.toString();
}
- public static String getContentType(OutputFormat format) {
+ public static String getContentType(OutputFormat format) throws OseeArgumentException {
String toReturn = "";
switch (format) {
case HTML:
@@ -80,7 +81,7 @@ public class OutputFactory {
toReturn = "application/rtf";
break;
default:
- throw new IllegalArgumentException(String.format("Unsupported format [%s]", format));
+ throw new OseeArgumentException("Unsupported format [%s]", format);
}
return toReturn;
}
diff --git a/plugins/org.eclipse.osee.ote.ui.define/src/org/eclipse/osee/ote/ui/define/viewers/actions/EditDispositionAction.java b/plugins/org.eclipse.osee.ote.ui.define/src/org/eclipse/osee/ote/ui/define/viewers/actions/EditDispositionAction.java
index 588f782154..55343a9bf7 100644
--- a/plugins/org.eclipse.osee.ote.ui.define/src/org/eclipse/osee/ote/ui/define/viewers/actions/EditDispositionAction.java
+++ b/plugins/org.eclipse.osee.ote.ui.define/src/org/eclipse/osee/ote/ui/define/viewers/actions/EditDispositionAction.java
@@ -65,8 +65,8 @@ public class EditDispositionAction extends AbstractActionHandler {
private void checkPermissions(Artifact artifact) throws OseeCoreException {
if (true != AccessControlManager.hasPermission(artifact, PermissionEnum.READ)) {
- throw new OseeArgumentException(String.format("The user %s does not have read access to %s",
- UserManager.getUser(), artifact));
+ throw new OseeArgumentException("The user %s does not have read access to %s",
+ UserManager.getUser(), artifact);
}
}
}
diff --git a/plugins/org.eclipse.osee.ote.ui.define/src/org/eclipse/osee/ote/ui/define/viewers/actions/OpenInArtifactEditor.java b/plugins/org.eclipse.osee.ote.ui.define/src/org/eclipse/osee/ote/ui/define/viewers/actions/OpenInArtifactEditor.java
index 956da2a3f0..e7e31877f2 100644
--- a/plugins/org.eclipse.osee.ote.ui.define/src/org/eclipse/osee/ote/ui/define/viewers/actions/OpenInArtifactEditor.java
+++ b/plugins/org.eclipse.osee.ote.ui.define/src/org/eclipse/osee/ote/ui/define/viewers/actions/OpenInArtifactEditor.java
@@ -65,8 +65,8 @@ public class OpenInArtifactEditor extends AbstractActionHandler {
private void checkPermissions(Artifact artifact) throws OseeCoreException {
if (true != AccessControlManager.hasPermission(artifact, PermissionEnum.READ)) {
- throw new OseeArgumentException(String.format("The user %s does not have read access to %s",
- UserManager.getUser(), artifact));
+ throw new OseeArgumentException("The user %s does not have read access to %s",
+ UserManager.getUser(), artifact);
}
}
}
diff --git a/plugins/org.eclipse.osee.ote.ui.message/META-INF/MANIFEST.MF b/plugins/org.eclipse.osee.ote.ui.message/META-INF/MANIFEST.MF
index cfcd3ce2d2..54c7fded29 100644
--- a/plugins/org.eclipse.osee.ote.ui.message/META-INF/MANIFEST.MF
+++ b/plugins/org.eclipse.osee.ote.ui.message/META-INF/MANIFEST.MF
@@ -29,4 +29,5 @@ Export-Package: org.eclipse.osee.ote.ui.message,
org.eclipse.osee.ote.ui.message.view,
org.eclipse.osee.ote.ui.message.watch
Bundle-RequiredExecutionEnvironment: JavaSE-1.6
-Import-Package: org.eclipse.osee.framework.core.operation
+Import-Package: org.eclipse.osee.framework.core.exception,
+ org.eclipse.osee.framework.core.operation
diff --git a/plugins/org.eclipse.osee.ote.ui.message/src/org/eclipse/osee/ote/ui/message/watch/WatchView.java b/plugins/org.eclipse.osee.ote.ui.message/src/org/eclipse/osee/ote/ui/message/watch/WatchView.java
index c0d68b92b3..96c2ab84a2 100644
--- a/plugins/org.eclipse.osee.ote.ui.message/src/org/eclipse/osee/ote/ui/message/watch/WatchView.java
+++ b/plugins/org.eclipse.osee.ote.ui.message/src/org/eclipse/osee/ote/ui/message/watch/WatchView.java
@@ -30,7 +30,6 @@ import org.eclipse.core.runtime.IConfigurationElement;
import org.eclipse.core.runtime.IExtension;
import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.InvalidRegistryObjectException;
import org.eclipse.core.runtime.Platform;
import org.eclipse.core.runtime.jobs.Job;
import org.eclipse.jface.action.Action;
@@ -49,6 +48,7 @@ import org.eclipse.jface.window.Window;
import org.eclipse.jface.wizard.WizardDialog;
import org.eclipse.nebula.widgets.xviewer.XViewer;
import org.eclipse.osee.connection.service.IServiceConnector;
+import org.eclipse.osee.framework.core.exception.OseeArgumentException;
import org.eclipse.osee.framework.jdk.core.util.AFile;
import org.eclipse.osee.framework.jdk.core.util.benchmark.Benchmark;
import org.eclipse.osee.framework.logging.OseeLog;
@@ -300,28 +300,20 @@ public final class WatchView extends ViewPart implements IActionable, IMessageDi
if (icon != null) {
URL url = bundle.getEntry(icon);
if (url == null) {
- throw new IllegalArgumentException(String.format("Invalid icon path [{%s}/%s]",
- el.getContributor().getName(), icon));
+ throw new OseeArgumentException("Invalid icon path [{%s}/%s]", el.getContributor().getName(),
+ icon);
} else {
ImageDescriptor desc = ImageDescriptor.createFromURL(url);
Image img = desc.createImage();
if (img == null) {
- throw new IllegalArgumentException(String.format("Unable to create Image from [{%s}/%s]",
- el.getContributor().getName(), icon));
+ throw new OseeArgumentException("Unable to create Image from [{%s}/%s]",
+ el.getContributor().getName(), icon);
} else {
btn.setImage(img);
}
}
}
- } catch (InvalidRegistryObjectException ex) {
- OseeLog.log(Activator.class, Level.SEVERE, ex);
- } catch (ClassNotFoundException ex) {
- OseeLog.log(Activator.class, Level.SEVERE, ex);
- } catch (InstantiationException ex) {
- OseeLog.log(Activator.class, Level.SEVERE, ex);
- } catch (IllegalAccessException ex) {
- OseeLog.log(Activator.class, Level.SEVERE, ex);
- } catch (IllegalArgumentException ex) {
+ } catch (Exception ex) {
OseeLog.log(Activator.class, Level.SEVERE, ex);
}
}
diff --git a/plugins/org.eclipse.osee.support.test.util/src/org/eclipse/osee/support/test/util/TestUtil.java b/plugins/org.eclipse.osee.support.test.util/src/org/eclipse/osee/support/test/util/TestUtil.java
index 019349a974..2e7070aa77 100644
--- a/plugins/org.eclipse.osee.support.test.util/src/org/eclipse/osee/support/test/util/TestUtil.java
+++ b/plugins/org.eclipse.osee.support.test.util/src/org/eclipse/osee/support/test/util/TestUtil.java
@@ -115,8 +115,8 @@ public class TestUtil {
}
}
if (numExceptions > 0) {
- throw new OseeStateException(
- "SevereLoggingMonitor found " + numExceptions + " exceptions (see console for details)!");
+ throw new OseeStateException("SevereLoggingMonitor found [%d] exceptions (see console for details)!",
+ numExceptions);
}
}
}

Back to the top