diff --git a/.classpath b/.classpath new file mode 100644 index 00000000..f7e4a1dd --- /dev/null +++ b/.classpath @@ -0,0 +1,40 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/.gitignore b/.gitignore new file mode 100644 index 00000000..c49342be --- /dev/null +++ b/.gitignore @@ -0,0 +1,5 @@ +.idea/ +target/ + +*.class +*.log \ No newline at end of file diff --git a/.metadata/.lock b/.metadata/.lock new file mode 100644 index 00000000..e69de29b diff --git a/.metadata/.mylyn/.taskListIndex/segments_1 b/.metadata/.mylyn/.taskListIndex/segments_1 new file mode 100644 index 00000000..34f54fb8 Binary files /dev/null and b/.metadata/.mylyn/.taskListIndex/segments_1 differ diff --git a/.metadata/.mylyn/.taskListIndex/write.lock b/.metadata/.mylyn/.taskListIndex/write.lock new file mode 100644 index 00000000..e69de29b diff --git a/.metadata/.mylyn/repositories.xml.zip b/.metadata/.mylyn/repositories.xml.zip new file mode 100644 index 00000000..741bd0f8 Binary files /dev/null and b/.metadata/.mylyn/repositories.xml.zip differ diff --git a/.metadata/.mylyn/tasks.xml.zip b/.metadata/.mylyn/tasks.xml.zip new file mode 100644 index 00000000..b8c83c42 Binary files /dev/null and b/.metadata/.mylyn/tasks.xml.zip differ diff --git a/.metadata/.plugins/org.eclipse.core.resources/.projects/.org.eclipse.egit.core.cmp/.location b/.metadata/.plugins/org.eclipse.core.resources/.projects/.org.eclipse.egit.core.cmp/.location new file mode 100644 index 00000000..431eca5c Binary files /dev/null and b/.metadata/.plugins/org.eclipse.core.resources/.projects/.org.eclipse.egit.core.cmp/.location differ diff --git a/.metadata/.plugins/org.eclipse.core.resources/.root/.indexes/history.version b/.metadata/.plugins/org.eclipse.core.resources/.root/.indexes/history.version new file mode 100644 index 00000000..25cb955b --- /dev/null +++ b/.metadata/.plugins/org.eclipse.core.resources/.root/.indexes/history.version @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/.metadata/.plugins/org.eclipse.core.resources/.root/.indexes/properties.index b/.metadata/.plugins/org.eclipse.core.resources/.root/.indexes/properties.index new file mode 100644 index 00000000..d2372511 Binary files /dev/null and b/.metadata/.plugins/org.eclipse.core.resources/.root/.indexes/properties.index differ diff --git a/.metadata/.plugins/org.eclipse.core.resources/.root/.indexes/properties.version b/.metadata/.plugins/org.eclipse.core.resources/.root/.indexes/properties.version new file mode 100644 index 00000000..6b2aaa76 --- /dev/null +++ b/.metadata/.plugins/org.eclipse.core.resources/.root/.indexes/properties.version @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/.metadata/.plugins/org.eclipse.core.resources/.root/1.tree b/.metadata/.plugins/org.eclipse.core.resources/.root/1.tree new file mode 100644 index 00000000..a7d31773 Binary files /dev/null and b/.metadata/.plugins/org.eclipse.core.resources/.root/1.tree differ diff --git a/.metadata/.plugins/org.eclipse.core.resources/.safetable/org.eclipse.core.resources b/.metadata/.plugins/org.eclipse.core.resources/.safetable/org.eclipse.core.resources new file mode 100644 index 00000000..59e2b315 Binary files /dev/null and b/.metadata/.plugins/org.eclipse.core.resources/.safetable/org.eclipse.core.resources differ diff --git a/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.core.resources.prefs b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.core.resources.prefs new file mode 100644 index 00000000..30841ebf --- /dev/null +++ b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.core.resources.prefs @@ -0,0 +1,3 @@ +eclipse.preferences.version=1 +encoding=UTF-8 +version=1 diff --git a/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.debug.ui.prefs b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.debug.ui.prefs new file mode 100644 index 00000000..98d8634a --- /dev/null +++ b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.debug.ui.prefs @@ -0,0 +1,2 @@ +eclipse.preferences.version=1 +org.eclipse.debug.ui.PREF_LAUNCH_PERSPECTIVES=\r\n\r\n diff --git a/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.egit.core.prefs b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.egit.core.prefs new file mode 100644 index 00000000..d0d25a1d --- /dev/null +++ b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.egit.core.prefs @@ -0,0 +1,3 @@ +GitRepositoriesView.GitDirectories=C\:\\Users\\zlyda\\OneDrive\\Pulpit\\pio_git_rhymers\\.git; +GitRepositoriesView.GitDirectories.relative=.git; +eclipse.preferences.version=1 diff --git a/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.egit.ui.prefs b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.egit.ui.prefs new file mode 100644 index 00000000..fde86d80 --- /dev/null +++ b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.egit.ui.prefs @@ -0,0 +1,2 @@ +RepositorySearchDialogSearchPath=C\:\\Users\\zlyda\\OneDrive\\Pulpit\\pio_git_rhymers +eclipse.preferences.version=1 diff --git a/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.epp.mpc.ui.prefs b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.epp.mpc.ui.prefs new file mode 100644 index 00000000..0d8d62a4 --- /dev/null +++ b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.epp.mpc.ui.prefs @@ -0,0 +1,2 @@ +CatalogDescriptor=https\://marketplace.eclipse.org +eclipse.preferences.version=1 diff --git a/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.jdt.core.prefs b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.jdt.core.prefs new file mode 100644 index 00000000..a84e30e9 --- /dev/null +++ b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.jdt.core.prefs @@ -0,0 +1,8 @@ +eclipse.preferences.version=1 +org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled +org.eclipse.jdt.core.compiler.codegen.targetPlatform=17 +org.eclipse.jdt.core.compiler.compliance=17 +org.eclipse.jdt.core.compiler.problem.assertIdentifier=error +org.eclipse.jdt.core.compiler.problem.enumIdentifier=error +org.eclipse.jdt.core.compiler.release=enabled +org.eclipse.jdt.core.compiler.source=17 diff --git a/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.jdt.launching.prefs b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.jdt.launching.prefs new file mode 100644 index 00000000..2b497be4 --- /dev/null +++ b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.jdt.launching.prefs @@ -0,0 +1,2 @@ +eclipse.preferences.version=1 +org.eclipse.jdt.launching.PREF_VM_XML=\r\n\r\n \r\n \r\n \r\n\r\n diff --git a/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.jdt.ui.prefs b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.jdt.ui.prefs new file mode 100644 index 00000000..c5f59cec --- /dev/null +++ b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.jdt.ui.prefs @@ -0,0 +1,6 @@ +eclipse.preferences.version=1 +org.eclipse.jdt.ui.formatterprofiles.version=23 +spelling_locale_initialized=true +typefilter_migrated_2=true +useAnnotationsPrefPage=true +useQuickDiffPrefPage=true diff --git a/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.jsch.core.prefs b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.jsch.core.prefs new file mode 100644 index 00000000..d56c53f1 --- /dev/null +++ b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.jsch.core.prefs @@ -0,0 +1,2 @@ +eclipse.preferences.version=1 +org.eclipse.jsch.core.hasChangedDefaultWin32SshHome=true diff --git a/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.m2e.discovery.prefs b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.m2e.discovery.prefs new file mode 100644 index 00000000..67b1d96c --- /dev/null +++ b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.m2e.discovery.prefs @@ -0,0 +1,2 @@ +eclipse.preferences.version=1 +org.eclipse.m2e.discovery.pref.projects= diff --git a/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.mylyn.context.core.prefs b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.mylyn.context.core.prefs new file mode 100644 index 00000000..43e97e40 --- /dev/null +++ b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.mylyn.context.core.prefs @@ -0,0 +1,2 @@ +eclipse.preferences.version=1 +mylyn.attention.migrated=true diff --git a/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.mylyn.monitor.ui.prefs b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.mylyn.monitor.ui.prefs new file mode 100644 index 00000000..8d462a6c --- /dev/null +++ b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.mylyn.monitor.ui.prefs @@ -0,0 +1,2 @@ +eclipse.preferences.version=1 +org.eclipse.mylyn.monitor.activity.tracking.enabled.checked=true diff --git a/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.mylyn.tasks.ui.prefs b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.mylyn.tasks.ui.prefs new file mode 100644 index 00000000..2b60c21d --- /dev/null +++ b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.mylyn.tasks.ui.prefs @@ -0,0 +1,5 @@ +eclipse.preferences.version=1 +migrated.task.repositories.secure.store=true +org.eclipse.mylyn.tasks.ui.filters.nonmatching=true +org.eclipse.mylyn.tasks.ui.filters.nonmatching.encouraged=true +org.eclipse.mylyn.tasks.ui.welcome.message=true diff --git a/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.ui.ide.prefs b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.ui.ide.prefs new file mode 100644 index 00000000..1edd3399 --- /dev/null +++ b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.ui.ide.prefs @@ -0,0 +1,4 @@ +eclipse.preferences.version=1 +platformState=894244531891432 +quickStart=false +tipsAndTricks=true diff --git a/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.ui.prefs b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.ui.prefs new file mode 100644 index 00000000..08076f23 --- /dev/null +++ b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.ui.prefs @@ -0,0 +1,2 @@ +eclipse.preferences.version=1 +showIntro=false diff --git a/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.ui.workbench.prefs b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.ui.workbench.prefs new file mode 100644 index 00000000..7e380fb0 --- /dev/null +++ b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.ui.workbench.prefs @@ -0,0 +1,12 @@ +//org.eclipse.ui.commands/state/org.eclipse.ui.navigator.resources.nested.changeProjectPresentation/org.eclipse.ui.commands.radioState=false +PLUGINS_NOT_ACTIVATED_ON_STARTUP=;org.eclipse.m2e.discovery; +eclipse.preferences.version=1 +org.eclipse.ui.workbench.ACTIVE_NOFOCUS_TAB_BG_END=41,41,41 +org.eclipse.ui.workbench.ACTIVE_NOFOCUS_TAB_BG_START=43,44,45 +org.eclipse.ui.workbench.ACTIVE_NOFOCUS_TAB_TEXT_COLOR=204,204,204 +org.eclipse.ui.workbench.ACTIVE_TAB_BG_END=41,41,41 +org.eclipse.ui.workbench.ACTIVE_TAB_BG_START=43,44,45 +org.eclipse.ui.workbench.ACTIVE_TAB_TEXT_COLOR=221,221,221 +org.eclipse.ui.workbench.INACTIVE_TAB_BG_END=49,53,56 +org.eclipse.ui.workbench.INACTIVE_TAB_BG_START=59,64,66 +org.eclipse.ui.workbench.INACTIVE_TAB_TEXT_COLOR=187,187,187 diff --git a/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.urischeme.prefs b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.urischeme.prefs new file mode 100644 index 00000000..855d634b --- /dev/null +++ b/.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.urischeme.prefs @@ -0,0 +1,2 @@ +eclipse.preferences.version=1 +processedSchemes=,eclipse+command,eclipse+mpc diff --git a/.metadata/.plugins/org.eclipse.e4.workbench/workbench.xmi b/.metadata/.plugins/org.eclipse.e4.workbench/workbench.xmi new file mode 100644 index 00000000..352433a1 --- /dev/null +++ b/.metadata/.plugins/org.eclipse.e4.workbench/workbench.xmi @@ -0,0 +1,2454 @@ + + + + activeSchemeId:org.eclipse.ui.defaultAcceleratorConfiguration + + + + + + + + topLevel + shellMaximized + + + + + persp.actionSet:org.eclipse.mylyn.tasks.ui.navigation + persp.actionSet:org.eclipse.ui.cheatsheets.actionSet + persp.actionSet:org.eclipse.search.searchActionSet + persp.actionSet:org.eclipse.text.quicksearch.actionSet + persp.actionSet:org.eclipse.ui.edit.text.actionSet.annotationNavigation + persp.actionSet:org.eclipse.ui.edit.text.actionSet.navigation + persp.actionSet:org.eclipse.ui.edit.text.actionSet.convertLineDelimitersTo + persp.actionSet:org.eclipse.ui.externaltools.ExternalToolsSet + persp.actionSet:org.eclipse.ui.actionSet.keyBindings + persp.actionSet:org.eclipse.ui.actionSet.openFiles + persp.actionSet:org.eclipse.debug.ui.launchActionSet + persp.actionSet:org.eclipse.jdt.ui.JavaActionSet + persp.actionSet:org.eclipse.jdt.ui.JavaElementCreationActionSet + persp.actionSet:org.eclipse.ui.NavigateActionSet + persp.viewSC:org.eclipse.jdt.ui.PackageExplorer + persp.viewSC:org.eclipse.jdt.ui.TypeHierarchy + persp.viewSC:org.eclipse.jdt.ui.SourceView + persp.viewSC:org.eclipse.jdt.ui.JavadocView + persp.viewSC:org.eclipse.search.ui.views.SearchView + persp.viewSC:org.eclipse.ui.console.ConsoleView + persp.viewSC:org.eclipse.ui.views.ContentOutline + persp.viewSC:org.eclipse.ui.views.ProblemView + persp.viewSC:org.eclipse.ui.views.TaskList + persp.viewSC:org.eclipse.ui.views.ProgressView + persp.viewSC:org.eclipse.ui.navigator.ProjectExplorer + persp.viewSC:org.eclipse.ui.texteditor.TemplatesView + persp.viewSC:org.eclipse.pde.runtime.LogView + persp.newWizSC:org.eclipse.jdt.ui.wizards.JavaProjectWizard + persp.newWizSC:org.eclipse.jdt.ui.wizards.NewPackageCreationWizard + persp.newWizSC:org.eclipse.jdt.ui.wizards.NewClassCreationWizard + persp.newWizSC:org.eclipse.jdt.ui.wizards.NewInterfaceCreationWizard + persp.newWizSC:org.eclipse.jdt.ui.wizards.NewEnumCreationWizard + persp.newWizSC:org.eclipse.jdt.ui.wizards.NewRecordCreationWizard + persp.newWizSC:org.eclipse.jdt.ui.wizards.NewAnnotationCreationWizard + persp.newWizSC:org.eclipse.jdt.ui.wizards.NewSourceFolderCreationWizard + persp.newWizSC:org.eclipse.jdt.ui.wizards.NewSnippetFileCreationWizard + persp.newWizSC:org.eclipse.jdt.ui.wizards.NewJavaWorkingSetWizard + persp.newWizSC:org.eclipse.ui.wizards.new.folder + persp.newWizSC:org.eclipse.ui.wizards.new.file + persp.newWizSC:org.eclipse.ui.editors.wizards.UntitledTextFileWizard + persp.perspSC:org.eclipse.jdt.ui.JavaBrowsingPerspective + persp.perspSC:org.eclipse.debug.ui.DebugPerspective + persp.editorOnboardingImageUri:platform:/plugin/org.eclipse.jdt.ui/$nl$/icons/full/onboarding_jperspective.png + persp.editorOnboardingText:Open a file or drop files here to open them. + persp.showIn:org.eclipse.jdt.ui.PackageExplorer + persp.showIn:org.eclipse.team.ui.GenericHistoryView + persp.showIn:org.eclipse.ui.navigator.ProjectExplorer + persp.editorOnboardingCommand:Find Actions$$$Ctrl+3 + persp.editorOnboardingCommand:Show Key Assist$$$Ctrl+Shift+L + persp.editorOnboardingCommand:New$$$Ctrl+N + persp.editorOnboardingCommand:Open Type$$$Ctrl+Shift+T + persp.viewSC:org.eclipse.mylyn.tasks.ui.views.tasks + persp.newWizSC:org.eclipse.mylyn.tasks.ui.wizards.new.repository.task + persp.actionSet:org.eclipse.debug.ui.breakpointActionSet + persp.actionSet:org.eclipse.jdt.debug.ui.JDTDebugActionSet + persp.showIn:org.eclipse.egit.ui.RepositoriesView + persp.newWizSC:org.eclipse.m2e.core.wizards.Maven2ProjectWizard + persp.actionSet:org.eclipse.eclemma.ui.CoverageActionSet + persp.showIn:org.eclipse.eclemma.ui.CoverageView + persp.viewSC:org.eclipse.tm.terminal.view.ui.TerminalsView + persp.showIn:org.eclipse.tm.terminal.view.ui.TerminalsView + persp.viewSC:org.eclipse.jdt.bcoview.views.BytecodeOutlineView + persp.newWizSC:org.eclipse.jdt.junit.wizards.NewTestCaseCreationWizard + persp.actionSet:org.eclipse.jdt.junit.JUnitActionSet + persp.viewSC:org.eclipse.ant.ui.views.AntView + + + + org.eclipse.e4.primaryNavigationStack + active + + View + categoryTag:Java + + + View + categoryTag:Java + + + View + categoryTag:General + + + View + categoryTag:Java + + + + + View + categoryTag:Git + + + + + + + + + Minimized + + View + categoryTag:Mylyn + + + + org.eclipse.e4.secondaryNavigationStack + Minimized + + View + categoryTag:General + + + View + categoryTag:General + + + View + categoryTag:General + + + View + categoryTag:Java + + + View + categoryTag:Ant + + + + + + org.eclipse.e4.secondaryDataStack + + View + categoryTag:General + + + View + categoryTag:Java + + + View + categoryTag:Java + + + View + categoryTag:General + + + View + categoryTag:General + + + View + categoryTag:General + + + View + categoryTag:General + + + View + categoryTag:Terminal + + + + + + + + + View + categoryTag:Help + + + View + categoryTag:General + + + View + categoryTag:Help + + + + + + + View + categoryTag:Help + + + + + + View + categoryTag:General + + ViewMenu + menuContribution:menu + + + + + + + + View + categoryTag:Help + + ViewMenu + menuContribution:menu + + + + + + org.eclipse.e4.primaryDataStack + EditorStack + + + + + + + View + categoryTag:Java + active + activeOnClose + + ViewMenu + menuContribution:menu + + + + + + + View + categoryTag:Java + + + + + View + categoryTag:General + + + + + + View + categoryTag:General + + ViewMenu + menuContribution:menu + + + + + + + View + categoryTag:Java + + + + + View + categoryTag:Java + + + + + View + categoryTag:General + + + + + View + categoryTag:General + + + + + View + categoryTag:General + + + + + View + categoryTag:General + + + + + + View + categoryTag:General + + ViewMenu + menuContribution:menu + + + + + + + View + categoryTag:General + + + + + View + categoryTag:General + + + + + + View + categoryTag:Mylyn + + ViewMenu + menuContribution:menu + + + + + + + View + categoryTag:Git + + + + + + View + categoryTag:Terminal + + ViewMenu + menuContribution:menu + + + + + + + View + categoryTag:Java + + + + + View + categoryTag:Java + + + + + View + categoryTag:Ant + + + + toolbarSeparator + + + + Draggable + + + + toolbarSeparator + + + + Draggable + + + + + toolbarSeparator + + + + Draggable + + + Draggable + + + Draggable + + + Draggable + + + toolbarSeparator + + + + Draggable + + + + toolbarSeparator + + + + toolbarSeparator + + + + Draggable + + + stretch + SHOW_RESTORE_MENU + + + Draggable + HIDEABLE + SHOW_RESTORE_MENU + + + + + stretch + + + Draggable + + + Draggable + + + + + Draggable + + + + + TrimStack + Draggable + + + + + TrimStack + Draggable + + + TrimStack + Draggable + + + + + + + + + + + + + + + + + + + + + platform:win32 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + platform:win32 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Editor + removeOnHide + + + + + View + categoryTag:Ant + + + + + View + categoryTag:Gradle + + + + + View + categoryTag:Gradle + + + + + View + categoryTag:Debug + + + + + View + categoryTag:Debug + + + + + View + categoryTag:Debug + + + + + View + categoryTag:Debug + + + + + View + categoryTag:Debug + + + + + View + categoryTag:Debug + + + + + View + categoryTag:Debug + + + View + categoryTag:Debug + + + + + View + categoryTag:Java + + + + + View + categoryTag:Git + + + + + View + categoryTag:Git + + + + + View + categoryTag:Git + + + + + View + categoryTag:Git + NoRestore + + + + + View + categoryTag:Git + + + + + View + categoryTag:Help + + + + + View + categoryTag:Java + + + + + View + categoryTag:Java + + + + + View + categoryTag:Debug + + + + + View + categoryTag:Java + + + + + View + categoryTag:Java + + + + + View + categoryTag:Java + + + + + View + categoryTag:Java Browsing + + + + + View + categoryTag:Java Browsing + + + + + View + categoryTag:Java Browsing + + + + + View + categoryTag:Java Browsing + + + + + View + categoryTag:Java + + + + + View + categoryTag:General + + + + + View + categoryTag:Java + + + + + View + categoryTag:Java + + + + + View + categoryTag:Language Servers + + + + + View + categoryTag:Language Servers + + + + + View + categoryTag:Language Servers + + + + + View + categoryTag:Maven + + + + + View + categoryTag:Maven + + + + + View + categoryTag:Maven + + + + + View + categoryTag:Mylyn + + + + + View + categoryTag:Mylyn + + + + + View + categoryTag:Mylyn + + + + + View + categoryTag:Mylyn + + + + + View + categoryTag:Mylyn + + + + + View + categoryTag:Mylyn + + + + + View + categoryTag:Oomph + + + + + View + categoryTag:General + + + + + View + categoryTag:Version Control (Team) + + + + + View + categoryTag:Version Control (Team) + + + View + categoryTag:Help + + + + + View + categoryTag:Terminal + + + + + View + categoryTag:Other + + + + + View + categoryTag:General + + + + + View + categoryTag:General + + + + + View + categoryTag:Help + + + + + View + categoryTag:General + + + + + View + categoryTag:General + + + + + View + categoryTag:General + + + + + View + categoryTag:General + + + + + View + categoryTag:General + + + + + View + categoryTag:General + + + + + View + categoryTag:General + + + + + View + categoryTag:General + + + + + View + categoryTag:General + + + + + View + categoryTag:General + + + + + View + categoryTag:General + + + + glue + move_after:PerspectiveSpacer + SHOW_RESTORE_MENU + + + move_after:Spacer Glue + HIDEABLE + SHOW_RESTORE_MENU + + + glue + move_after:SearchField + SHOW_RESTORE_MENU + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/.metadata/.plugins/org.eclipse.egit.core/.org.eclipse.egit.core.cmp/.project b/.metadata/.plugins/org.eclipse.egit.core/.org.eclipse.egit.core.cmp/.project new file mode 100644 index 00000000..3c108561 --- /dev/null +++ b/.metadata/.plugins/org.eclipse.egit.core/.org.eclipse.egit.core.cmp/.project @@ -0,0 +1,11 @@ + + + .org.eclipse.egit.core.cmp + + + + + + + + diff --git a/.metadata/.plugins/org.eclipse.egit.core/.org.eclipse.egit.core.cmp/.settings/org.eclipse.core.resources.prefs b/.metadata/.plugins/org.eclipse.egit.core/.org.eclipse.egit.core.cmp/.settings/org.eclipse.core.resources.prefs new file mode 100644 index 00000000..99f26c02 --- /dev/null +++ b/.metadata/.plugins/org.eclipse.egit.core/.org.eclipse.egit.core.cmp/.settings/org.eclipse.core.resources.prefs @@ -0,0 +1,2 @@ +eclipse.preferences.version=1 +encoding/=UTF-8 diff --git a/.metadata/.plugins/org.eclipse.egit.ui/dialog_settings.xml b/.metadata/.plugins/org.eclipse.egit.ui/dialog_settings.xml new file mode 100644 index 00000000..5d854beb --- /dev/null +++ b/.metadata/.plugins/org.eclipse.egit.ui/dialog_settings.xml @@ -0,0 +1,29 @@ + +
+ + + + + + + + + + +
+
+ + + + + +
+
+
+ + + + + +
+
diff --git a/.metadata/.plugins/org.eclipse.epp.mpc.ui/dialog_settings.xml b/.metadata/.plugins/org.eclipse.epp.mpc.ui/dialog_settings.xml new file mode 100644 index 00000000..f3408aad --- /dev/null +++ b/.metadata/.plugins/org.eclipse.epp.mpc.ui/dialog_settings.xml @@ -0,0 +1,10 @@ + +
+
+ + + + + +
+
diff --git a/.metadata/.plugins/org.eclipse.jdt.core/assumedExternalFilesCache b/.metadata/.plugins/org.eclipse.jdt.core/assumedExternalFilesCache new file mode 100644 index 00000000..593f4708 Binary files /dev/null and b/.metadata/.plugins/org.eclipse.jdt.core/assumedExternalFilesCache differ diff --git a/.metadata/.plugins/org.eclipse.jdt.core/externalFilesCache b/.metadata/.plugins/org.eclipse.jdt.core/externalFilesCache new file mode 100644 index 00000000..593f4708 Binary files /dev/null and b/.metadata/.plugins/org.eclipse.jdt.core/externalFilesCache differ diff --git a/.metadata/.plugins/org.eclipse.jdt.core/javaLikeNames.txt b/.metadata/.plugins/org.eclipse.jdt.core/javaLikeNames.txt new file mode 100644 index 00000000..85863977 --- /dev/null +++ b/.metadata/.plugins/org.eclipse.jdt.core/javaLikeNames.txt @@ -0,0 +1 @@ +java \ No newline at end of file diff --git a/.metadata/.plugins/org.eclipse.jdt.core/nonChainingJarsCache b/.metadata/.plugins/org.eclipse.jdt.core/nonChainingJarsCache new file mode 100644 index 00000000..593f4708 Binary files /dev/null and b/.metadata/.plugins/org.eclipse.jdt.core/nonChainingJarsCache differ diff --git a/.metadata/.plugins/org.eclipse.jdt.core/variablesAndContainers.dat b/.metadata/.plugins/org.eclipse.jdt.core/variablesAndContainers.dat new file mode 100644 index 00000000..0edae4b2 Binary files /dev/null and b/.metadata/.plugins/org.eclipse.jdt.core/variablesAndContainers.dat differ diff --git a/.metadata/.plugins/org.eclipse.jdt.launching/.install.xml b/.metadata/.plugins/org.eclipse.jdt.launching/.install.xml new file mode 100644 index 00000000..4ec7236e --- /dev/null +++ b/.metadata/.plugins/org.eclipse.jdt.launching/.install.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/.metadata/.plugins/org.eclipse.jdt.launching/libraryInfos.xml b/.metadata/.plugins/org.eclipse.jdt.launching/libraryInfos.xml new file mode 100644 index 00000000..a91b9863 --- /dev/null +++ b/.metadata/.plugins/org.eclipse.jdt.launching/libraryInfos.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/.metadata/.plugins/org.eclipse.jdt.ui/OpenTypeHistory.xml b/.metadata/.plugins/org.eclipse.jdt.ui/OpenTypeHistory.xml new file mode 100644 index 00000000..a4ee3cbc --- /dev/null +++ b/.metadata/.plugins/org.eclipse.jdt.ui/OpenTypeHistory.xml @@ -0,0 +1,2 @@ + + diff --git a/.metadata/.plugins/org.eclipse.jdt.ui/QualifiedTypeNameHistory.xml b/.metadata/.plugins/org.eclipse.jdt.ui/QualifiedTypeNameHistory.xml new file mode 100644 index 00000000..9e390f50 --- /dev/null +++ b/.metadata/.plugins/org.eclipse.jdt.ui/QualifiedTypeNameHistory.xml @@ -0,0 +1,2 @@ + + diff --git a/.metadata/.plugins/org.eclipse.jdt.ui/dialog_settings.xml b/.metadata/.plugins/org.eclipse.jdt.ui/dialog_settings.xml new file mode 100644 index 00000000..8d177d26 --- /dev/null +++ b/.metadata/.plugins/org.eclipse.jdt.ui/dialog_settings.xml @@ -0,0 +1,19 @@ + +
+ + +
+ + + + + +
+
+ + + + + +
+
diff --git a/.metadata/.plugins/org.eclipse.m2e.core/workspaceState.ser b/.metadata/.plugins/org.eclipse.m2e.core/workspaceState.ser new file mode 100644 index 00000000..abbf8e52 Binary files /dev/null and b/.metadata/.plugins/org.eclipse.m2e.core/workspaceState.ser differ diff --git a/.metadata/.plugins/org.eclipse.m2e.logback/logback.2.6.0.20240217-1525.xml b/.metadata/.plugins/org.eclipse.m2e.logback/logback.2.6.0.20240217-1525.xml new file mode 100644 index 00000000..9effde76 --- /dev/null +++ b/.metadata/.plugins/org.eclipse.m2e.logback/logback.2.6.0.20240217-1525.xml @@ -0,0 +1,41 @@ + + + + %date [%thread] %-5level %logger{35} - %msg%n + + + ${org.eclipse.m2e.log.console.threshold:-OFF} + + + + + ${org.eclipse.m2e.log.dir}/0.log + + ${org.eclipse.m2e.log.dir}/%i.log + 1 + 10 + + + 10MB + + + %date [%thread] %-5level %logger{35} - %msg%n + + + + + + WARN + + + + + + + + + + + + + diff --git a/.metadata/.plugins/org.eclipse.mylyn.github.ui/avatars.ser b/.metadata/.plugins/org.eclipse.mylyn.github.ui/avatars.ser new file mode 100644 index 00000000..1e9a069c Binary files /dev/null and b/.metadata/.plugins/org.eclipse.mylyn.github.ui/avatars.ser differ diff --git a/.metadata/.plugins/org.eclipse.oomph.setup/workspace.setup b/.metadata/.plugins/org.eclipse.oomph.setup/workspace.setup new file mode 100644 index 00000000..1f73e14c --- /dev/null +++ b/.metadata/.plugins/org.eclipse.oomph.setup/workspace.setup @@ -0,0 +1,6 @@ + + diff --git a/.metadata/.plugins/org.eclipse.tips.ide/dialog_settings.xml b/.metadata/.plugins/org.eclipse.tips.ide/dialog_settings.xml new file mode 100644 index 00000000..5ca0b776 --- /dev/null +++ b/.metadata/.plugins/org.eclipse.tips.ide/dialog_settings.xml @@ -0,0 +1,3 @@ + +
+
diff --git a/.metadata/.plugins/org.eclipse.ui.cheatsheets/history.xml b/.metadata/.plugins/org.eclipse.ui.cheatsheets/history.xml new file mode 100644 index 00000000..ef48b6bf --- /dev/null +++ b/.metadata/.plugins/org.eclipse.ui.cheatsheets/history.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/.metadata/.plugins/org.eclipse.ui.cheatsheets/org.eclipse.jdt.helloworld.xml b/.metadata/.plugins/org.eclipse.ui.cheatsheets/org.eclipse.jdt.helloworld.xml new file mode 100644 index 00000000..e688b756 --- /dev/null +++ b/.metadata/.plugins/org.eclipse.ui.cheatsheets/org.eclipse.jdt.helloworld.xml @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/.metadata/.plugins/org.eclipse.ui.editors/dialog_settings.xml b/.metadata/.plugins/org.eclipse.ui.editors/dialog_settings.xml new file mode 100644 index 00000000..50f1edb3 --- /dev/null +++ b/.metadata/.plugins/org.eclipse.ui.editors/dialog_settings.xml @@ -0,0 +1,5 @@ + +
+
+
+
diff --git a/.metadata/.plugins/org.eclipse.ui.ide/dialog_settings.xml b/.metadata/.plugins/org.eclipse.ui.ide/dialog_settings.xml new file mode 100644 index 00000000..311c43d5 --- /dev/null +++ b/.metadata/.plugins/org.eclipse.ui.ide/dialog_settings.xml @@ -0,0 +1,28 @@ + +
+
+ + + + + + + +
+ + + + + +
+
+
+
+ + + + + +
+
+
diff --git a/.metadata/.plugins/org.eclipse.ui.intro/dialog_settings.xml b/.metadata/.plugins/org.eclipse.ui.intro/dialog_settings.xml new file mode 100644 index 00000000..4868369e --- /dev/null +++ b/.metadata/.plugins/org.eclipse.ui.intro/dialog_settings.xml @@ -0,0 +1,4 @@ + +
+ +
diff --git a/.metadata/.plugins/org.eclipse.ui.intro/introstate b/.metadata/.plugins/org.eclipse.ui.intro/introstate new file mode 100644 index 00000000..02f134f0 --- /dev/null +++ b/.metadata/.plugins/org.eclipse.ui.intro/introstate @@ -0,0 +1,2 @@ + + \ No newline at end of file diff --git a/.metadata/.plugins/org.eclipse.ui.workbench/dialog_settings.xml b/.metadata/.plugins/org.eclipse.ui.workbench/dialog_settings.xml new file mode 100644 index 00000000..3a09262a --- /dev/null +++ b/.metadata/.plugins/org.eclipse.ui.workbench/dialog_settings.xml @@ -0,0 +1,16 @@ + +
+
+ + + + +
+ + + + + +
+
+
diff --git a/.metadata/.plugins/org.eclipse.ui.workbench/workingsets.xml b/.metadata/.plugins/org.eclipse.ui.workbench/workingsets.xml new file mode 100644 index 00000000..9553d666 --- /dev/null +++ b/.metadata/.plugins/org.eclipse.ui.workbench/workingsets.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/.metadata/version.ini b/.metadata/version.ini new file mode 100644 index 00000000..9c870771 --- /dev/null +++ b/.metadata/version.ini @@ -0,0 +1,3 @@ +#Wed May 22 21:28:28 CEST 2024 +org.eclipse.core.runtime=2 +org.eclipse.platform=4.31.100.v20240229-0520 diff --git a/.project b/.project new file mode 100644 index 00000000..4ee4a323 --- /dev/null +++ b/.project @@ -0,0 +1,23 @@ + + + pio_git_rhymers + + + + + + org.eclipse.jdt.core.javabuilder + + + + + org.eclipse.m2e.core.maven2Builder + + + + + + org.eclipse.jdt.core.javanature + org.eclipse.m2e.core.maven2Nature + + diff --git a/.settings/org.eclipse.core.resources.prefs b/.settings/org.eclipse.core.resources.prefs new file mode 100644 index 00000000..5b781ec6 --- /dev/null +++ b/.settings/org.eclipse.core.resources.prefs @@ -0,0 +1,3 @@ +eclipse.preferences.version=1 +encoding//src/main/java=UTF-8 +encoding//src/test/java=UTF-8 diff --git a/.settings/org.eclipse.jdt.core.prefs b/.settings/org.eclipse.jdt.core.prefs new file mode 100644 index 00000000..2f5cc74c --- /dev/null +++ b/.settings/org.eclipse.jdt.core.prefs @@ -0,0 +1,8 @@ +eclipse.preferences.version=1 +org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8 +org.eclipse.jdt.core.compiler.compliance=1.8 +org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled +org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning +org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=ignore +org.eclipse.jdt.core.compiler.release=disabled +org.eclipse.jdt.core.compiler.source=1.8 diff --git a/src/main/java/edu/kis/vh/nursery/DefaultCountingOutRhymer.java b/src/main/java/edu/kis/vh/nursery/DefaultCountingOutRhymer.java new file mode 100644 index 00000000..676ce927 --- /dev/null +++ b/src/main/java/edu/kis/vh/nursery/DefaultCountingOutRhymer.java @@ -0,0 +1,44 @@ +package edu.kis.vh.nursery; + +public class DefaultCountingOutRhymer { + private static final int CAPACITY = 12; + private static final int EMPTY_STACK_INDICATOR = -1; + private static final int FULL_STACK_INDICATOR = CAPACITY - 1; + private static final int DEFAULT_VALUE = -1; + + private static final int TOTAL_NUMBERS = 12; + private static final int EMPTY = -1; + private static final int MAX_CAPACITY = TOTAL_NUMBERS - 1; + + private int[] NUMBERS = new int[TOTAL_NUMBERS]; + + private int total = EMPTY; + + public void countIn(int in) { + if (!isFull()) + numbers[++total] = in; + } + public boolean callCheck() { + return total == EMPTY; + } + + public boolean isFull() { + return total == MAX_CAPACITY; + } + + protected int peekaboo() { + if (callCheck()) + return EMPTY; + return numbers[total]; + } + public int countOut() { + if (callCheck()) + return EMPTY; + return numbers[total--]; + } + + public int getTotal() { + return total; + } + +} diff --git a/src/main/java/edu/kis/vh/nursery/FIFORhymer.java b/src/main/java/edu/kis/vh/nursery/FIFORhymer.java index 28591ada..9e5c29ba 100644 --- a/src/main/java/edu/kis/vh/nursery/FIFORhymer.java +++ b/src/main/java/edu/kis/vh/nursery/FIFORhymer.java @@ -1,21 +1,14 @@ package edu.kis.vh.nursery; -public class FIFORhymer extends defaultCountingOutRhymer { - - public defaultCountingOutRhymer temp = new defaultCountingOutRhymer(); - +private class FIFORhymer extends DefaultCountingOutRhymer { + public DefaultCountingOutRhymer temp = new DefaultCountingOutRhymer(); @Override public int countOut() { while (!callCheck()) - - temp.countIn(super.countOut()); - - int ret = temp.countOut(); - - while (!temp.callCheck()) - - countIn(temp.countOut()); - + temp.countIn(super.countOut()); + int ret = temp.countOut(); + while (!temp.callCheck()) + countIn(temp.countOut()); return ret; } } diff --git a/src/main/java/edu/kis/vh/nursery/HanoiRhymer.java b/src/main/java/edu/kis/vh/nursery/HanoiRhymer.java index 755b2d58..28d2c6b4 100644 --- a/src/main/java/edu/kis/vh/nursery/HanoiRhymer.java +++ b/src/main/java/edu/kis/vh/nursery/HanoiRhymer.java @@ -1,17 +1,32 @@ package edu.kis.vh.nursery; -public class HanoiRhymer extends defaultCountingOutRhymer { - -int totalRejected = 0; +/** + * HanoiRhymer + */ +public class HanoiRhymer extends DefaultCountingOutRhymer { + /** + * Total rejected + */ + private int totalRejected = 0; + /** + * + * @return total rejected calls + */ public int reportRejected() { return totalRejected; } + /** + * + * @param in in + * + */ + @Override public void countIn(int in) { - if (!callCheck() && in > peekaboo()) + if (!callCheck() && in > peekaboo()) totalRejected++; - else - super.countIn(in); + else + super.countIn(in); } -} +} \ No newline at end of file diff --git a/src/main/java/edu/kis/vh/nursery/defaultCountingOutRhymer.java b/src/main/java/edu/kis/vh/nursery/defaultCountingOutRhymer.java deleted file mode 100644 index 199abf6d..00000000 --- a/src/main/java/edu/kis/vh/nursery/defaultCountingOutRhymer.java +++ /dev/null @@ -1,34 +0,0 @@ -package edu.kis.vh.nursery; - -public class defaultCountingOutRhymer { - - private int[] NUMBERS = new int[12]; - - public int total = -1; - - public void countIn(int in) { - if (!isFull()) - NUMBERS[++total] = in; - } - - public boolean callCheck() { - return total == -1; - } - - public boolean isFull() { - return total == 11; - } - - protected int peekaboo() { - if (callCheck()) - return -1; - return NUMBERS[total]; - } - - public int countOut() { - if (callCheck()) - return -1; - return NUMBERS[total--]; - } - -} diff --git a/src/main/java/edu/kis/vh/nursery/factory/DefaultRhymersFactory.java b/src/main/java/edu/kis/vh/nursery/factory/DefaultRhymersFactory.java index 60ba2a16..537d50ae 100644 --- a/src/main/java/edu/kis/vh/nursery/factory/DefaultRhymersFactory.java +++ b/src/main/java/edu/kis/vh/nursery/factory/DefaultRhymersFactory.java @@ -1,29 +1,29 @@ package edu.kis.vh.nursery.factory; -import edu.kis.vh.nursery.defaultCountingOutRhymer; +import edu.kis.vh.nursery.DefaultCountingOutRhymer; import edu.kis.vh.nursery.FIFORhymer; import edu.kis.vh.nursery.HanoiRhymer; -import edu.kis.vh.nursery.factory.Rhymersfactory; +import edu.kis.vh.nursery.factory.RhymersFactory; -public class DefaultRhymersFactory implements Rhymersfactory { +public class DefaultRhymersFactory implements RhymersFactory { @Override - public defaultCountingOutRhymer GetStandardRhymer() { - return new defaultCountingOutRhymer(); + public DefaultCountingOutRhymer getStandardRhymer() { + return new DefaultCountingOutRhymer(); } @Override - public defaultCountingOutRhymer GetFalseRhymer() { - return new defaultCountingOutRhymer(); + public DefaultCountingOutRhymer getFalseRhymer() { + return new DefaultCountingOutRhymer(); } @Override - public defaultCountingOutRhymer GetFIFORhymer() { + public DefaultCountingOutRhymer getFIFORhymer() { return new FIFORhymer(); } @Override - public defaultCountingOutRhymer GetHanoiRhymer() { + public DefaultCountingOutRhymer getHanoiRhymer() { return new HanoiRhymer(); } diff --git a/src/main/java/edu/kis/vh/nursery/factory/RhymersFactory.java b/src/main/java/edu/kis/vh/nursery/factory/RhymersFactory.java new file mode 100644 index 00000000..0db3ac2a --- /dev/null +++ b/src/main/java/edu/kis/vh/nursery/factory/RhymersFactory.java @@ -0,0 +1,15 @@ +package edu.kis.vh.nursery.factory; + +import edu.kis.vh.nursery.DefaultCountingOutRhymer; + + public interface RhymersFactory { + + public DefaultCountingOutRhymer getStandardRhymer(); + + public DefaultCountingOutRhymer getFalseRhymer(); + + public DefaultCountingOutRhymer getFIFORhymer(); + + public DefaultCountingOutRhymer getHanoiRhymer(); + + } diff --git a/src/main/java/edu/kis/vh/nursery/factory/Rhymersfactory.java b/src/main/java/edu/kis/vh/nursery/factory/Rhymersfactory.java deleted file mode 100644 index 033755d0..00000000 --- a/src/main/java/edu/kis/vh/nursery/factory/Rhymersfactory.java +++ /dev/null @@ -1,15 +0,0 @@ -package edu.kis.vh.nursery.factory; - -import edu.kis.vh.nursery.defaultCountingOutRhymer; - - public interface Rhymersfactory { - - public defaultCountingOutRhymer GetStandardRhymer(); - - public defaultCountingOutRhymer GetFalseRhymer(); - - public defaultCountingOutRhymer GetFIFORhymer(); - - public defaultCountingOutRhymer GetHanoiRhymer(); - - } diff --git a/src/main/java/edu/kis/vh/nursery/list/Node.java b/src/main/java/edu/kis/vh/nursery/list/Node.java index 0a2cd75e..b5af282e 100644 --- a/src/main/java/edu/kis/vh/nursery/list/Node.java +++ b/src/main/java/edu/kis/vh/nursery/list/Node.java @@ -2,8 +2,24 @@ public class Node { - public int value; - public Node prev, next; + private int value; + private Node prev, next; + + public Node (int value) { + this.value = value; + } + + public int getValue() { + return value; + } + + public Node getPrev() { + return prev; + } + + public Node getNext() { + return next; + } public Node(int i) { value = i; diff --git a/src/test/java/edu/kis/vh/nursery/RhymersDemo.java b/src/test/java/edu/kis/vh/nursery/RhymersDemo.java index 05aba9fa..53461172 100644 --- a/src/test/java/edu/kis/vh/nursery/RhymersDemo.java +++ b/src/test/java/edu/kis/vh/nursery/RhymersDemo.java @@ -1,35 +1,43 @@ package edu.kis.vh.nursery; -import edu.kis.vh.nursery.defaultCountingOutRhymer; +import edu.kis.vh.nursery.DefaultCountingOutRhymer; import edu.kis.vh.nursery.HanoiRhymer; import edu.kis.vh.nursery.factory.DefaultRhymersFactory; -import edu.kis.vh.nursery.factory.Rhymersfactory; +import edu.kis.vh.nursery.factory.RhymersFactory; class RhymersDemo { + private static final int RHYMERS_COUNT = 4; + private static final int ELEMENTS_TO_COUNT_IN = 15; + private static final int RANDOM_BOUND = 20; + public static void main(String[] args) { - Rhymersfactory factory = new DefaultRhymersFactory(); - - defaultCountingOutRhymer[] rhymers = { factory.GetStandardRhymer(), factory.GetFalseRhymer(), - factory.GetFIFORhymer(), factory.GetHanoiRhymer()}; + RhymersFactory factory = new DefaultRhymersFactory(); + testRhymers(factory); + } + public static void testRhymers(Rhymersfactory factory) { + DefaultCountingOutRhymer[] rhymers = { factory.getStandardRhymer(), factory.getFalseRhymer(), + factory.getFIFORhymer(), factory.getHanoiRhymer()}; - for (int i = 1; i < 15; i++) - for (int j = 0; j < 3; j++) + for (int i = 1; i < ELEMENTS_TO_COUNT_IN; i++) { + for (int j = 0; j < RHYMERS_COUNT - 1; j++) { rhymers[j].countIn(i); + } + } java.util.Random rn = new java.util.Random(); - for (int i = 1; i < 15; i++) - rhymers[3].countIn(rn.nextInt(20)); + for (int i = 1; i < ELEMENTS_TO_COUNT_IN; i++) { + rhymers[RHYMERS_COUNT - 1].countIn(rn.nextInt(RANDOM_BOUND)); + } - for (int i = 0; i < rhymers.length; i++) { - while (!rhymers[i].callCheck()) + for (int i = 0; i < RHYMERS_COUNT; i++) { + while (!rhymers[i].callCheck()) { System.out.print(rhymers[i].countOut() + " "); + } System.out.println(); } System.out.println("total rejected is " - + ((HanoiRhymer) rhymers[3]).reportRejected()); - + + ((HanoiRhymer) rhymers[RHYMERS_COUNT - 1]).reportRejected()); } - -} \ No newline at end of file +} diff --git a/src/test/java/edu/kis/vh/nursery/RhymersJUnitTest.java b/src/test/java/edu/kis/vh/nursery/RhymersJUnitTest.java index 144906eb..f0f88d99 100644 --- a/src/test/java/edu/kis/vh/nursery/RhymersJUnitTest.java +++ b/src/test/java/edu/kis/vh/nursery/RhymersJUnitTest.java @@ -7,7 +7,7 @@ public class RhymersJUnitTest { @Test public void testCountIn() { - defaultCountingOutRhymer rhymer = new defaultCountingOutRhymer(); + DefaultCountingOutRhymer rhymer = new DefaultCountingOutRhymer(); int testValue = 4; rhymer.countIn(testValue); @@ -17,7 +17,7 @@ public void testCountIn() { @Test public void testCallCheck() { - defaultCountingOutRhymer rhymer = new defaultCountingOutRhymer(); + DefaultCountingOutRhymer rhymer = new DefaultCountingOutRhymer(); boolean result = rhymer.callCheck(); Assert.assertEquals(true, result); @@ -29,7 +29,7 @@ public void testCallCheck() { @Test public void testIsFull() { - defaultCountingOutRhymer rhymer = new defaultCountingOutRhymer(); + DefaultCountingOutRhymer rhymer = new DefaultCountingOutRhymer(); final int STACK_CAPACITY = 12; for (int i = 0; i < STACK_CAPACITY; i++) { boolean result = rhymer.isFull(); @@ -43,7 +43,7 @@ public void testIsFull() { @Test public void testPeekaboo() { - defaultCountingOutRhymer rhymer = new defaultCountingOutRhymer(); + DefaultCountingOutRhymer rhymer = new DefaultCountingOutRhymer(); final int EMPTY_STACK_VALUE = -1; int result = rhymer.peekaboo(); @@ -60,7 +60,7 @@ public void testPeekaboo() { @Test public void testCountOut() { - defaultCountingOutRhymer rhymer = new defaultCountingOutRhymer(); + DefaultCountingOutRhymer rhymer = new DefaultCountingOutRhymer(); final int EMPTY_STACK_VALUE = -1; int result = rhymer.countOut();