reorginazise

This commit is contained in:
Minh VU
2024-10-18 17:11:29 +02:00
parent 51fd5e6e07
commit f97509496e
14 changed files with 0 additions and 4 deletions

9
src/fr/api/Category.java Normal file
View File

@@ -0,0 +1,9 @@
package fr.istic.nplouzeau.cartaylor.api;
/**
* @author plouzeau
* <p>
* A public type to organize part types in categories
*/
public interface Category {
String getName();
}

View File

@@ -0,0 +1,6 @@
package fr.istic.nplouzeau.cartaylor.api;
import java.util.Set;
public interface CompatibilityChecker {
Set<PartType> getIncompatibilities(PartType reference);
Set<PartType> getRequirements(PartType reference);
}

View File

@@ -0,0 +1,8 @@
package fr.istic.nplouzeau.cartaylor.api;
import java.util.Set;
public interface CompatibilityManager extends CompatibilityChecker {
void addIncompatibilities(PartType reference,Set<PartType> target);
void removeIncompatibility(PartType reference, PartType target);
void addRequirements(PartType reference, Set<PartType> target);
void removeRequirement(PartType reference, PartType target);
}

View File

@@ -0,0 +1,11 @@
package fr.istic.nplouzeau.cartaylor.api;
import java.util.Set;
public interface Configuration {
boolean isValid();
boolean isComplete();
Set<PartType> getSelectedParts();
void selectPart(PartType chosenPart);
PartType getSelectionForCategory(Category category);
void unselectPartType(Category categoryToClear);
void clear();
}

View File

@@ -0,0 +1,8 @@
package fr.istic.nplouzeau.cartaylor.api;
import java.util.Set;
public interface Configurator {
Set<Category> getCategories();
Set<PartType> getVariants(Category category);
Configuration getConfiguration();
CompatibilityChecker getCompatibilityChecker();
}

5
src/fr/api/PartType.java Normal file
View File

@@ -0,0 +1,5 @@
package fr.istic.nplouzeau.cartaylor.api;
public interface PartType {
String getName();
Category getCategory();
}