Added my project

main
Najlae LAMBARAA 2 years ago
commit f1ecd0bc36

BIN
.DS_Store vendored

Binary file not shown.

@ -0,0 +1,710 @@
// !$*UTF8*$!
{
archiveVersion = 1;
classes = {
};
objectVersion = 56;
objects = {
/* Begin PBXBuildFile section */
EC281BBF2A4523CD00AAA912 /* BlocItem.swift in Sources */ = {isa = PBXBuildFile; fileRef = EC281BBE2A4523CD00AAA912 /* BlocItem.swift */; };
EC48A2342A1CE019008DB387 /* CalculatorApp.swift in Sources */ = {isa = PBXBuildFile; fileRef = EC48A2332A1CE019008DB387 /* CalculatorApp.swift */; };
EC48A2362A1CE019008DB387 /* ContentView.swift in Sources */ = {isa = PBXBuildFile; fileRef = EC48A2352A1CE019008DB387 /* ContentView.swift */; };
EC48A2382A1CE01A008DB387 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = EC48A2372A1CE01A008DB387 /* Assets.xcassets */; };
EC48A23B2A1CE01A008DB387 /* Preview Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = EC48A23A2A1CE01A008DB387 /* Preview Assets.xcassets */; };
EC48A2452A1CE01A008DB387 /* CalculatorTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = EC48A2442A1CE01A008DB387 /* CalculatorTests.swift */; };
EC48A24F2A1CE01A008DB387 /* CalculatorUITests.swift in Sources */ = {isa = PBXBuildFile; fileRef = EC48A24E2A1CE01A008DB387 /* CalculatorUITests.swift */; };
EC48A2512A1CE01A008DB387 /* CalculatorUITestsLaunchTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = EC48A2502A1CE01A008DB387 /* CalculatorUITestsLaunchTests.swift */; };
EC48A25F2A1CFDE8008DB387 /* Matieres.swift in Sources */ = {isa = PBXBuildFile; fileRef = EC48A25E2A1CFDE8008DB387 /* Matieres.swift */; };
EC48A2612A1CFEC7008DB387 /* UE.swift in Sources */ = {isa = PBXBuildFile; fileRef = EC48A2602A1CFEC7008DB387 /* UE.swift */; };
EC48A2642A1D0214008DB387 /* HomeView.swift in Sources */ = {isa = PBXBuildFile; fileRef = EC48A2632A1D0214008DB387 /* HomeView.swift */; };
EC48A26B2A1D10A0008DB387 /* EditView.swift in Sources */ = {isa = PBXBuildFile; fileRef = EC48A26A2A1D10A0008DB387 /* EditView.swift */; };
EC5D85462A41AD0F00BBB920 /* Editpage.swift in Sources */ = {isa = PBXBuildFile; fileRef = EC5D85452A41AD0F00BBB920 /* Editpage.swift */; };
EC5D854A2A41BBB700BBB920 /* Manager.swift in Sources */ = {isa = PBXBuildFile; fileRef = EC5D85492A41BBB700BBB920 /* Manager.swift */; };
EC5D854C2A41BBDD00BBB920 /* DataManager.swift in Sources */ = {isa = PBXBuildFile; fileRef = EC5D854B2A41BBDD00BBB920 /* DataManager.swift */; };
EC5D85502A41D17100BBB920 /* EditMatView.swift in Sources */ = {isa = PBXBuildFile; fileRef = EC5D854F2A41D17100BBB920 /* EditMatView.swift */; };
EC5D85522A41E4F900BBB920 /* BlocView.swift in Sources */ = {isa = PBXBuildFile; fileRef = EC5D85512A41E4F900BBB920 /* BlocView.swift */; };
EC5D85542A41F13100BBB920 /* ManagerVM.swift in Sources */ = {isa = PBXBuildFile; fileRef = EC5D85532A41F13100BBB920 /* ManagerVM.swift */; };
EC5D85562A43190300BBB920 /* AddMat.swift in Sources */ = {isa = PBXBuildFile; fileRef = EC5D85552A43190300BBB920 /* AddMat.swift */; };
EC8F56A52A39920700BBD572 /* UeVM.swift in Sources */ = {isa = PBXBuildFile; fileRef = EC8F56A42A39920700BBD572 /* UeVM.swift */; };
EC8F56A72A399CC600BBD572 /* ArrayExtension.swift in Sources */ = {isa = PBXBuildFile; fileRef = EC8F56A62A399CC600BBD572 /* ArrayExtension.swift */; };
EC8F56A92A3BA6CB00BBD572 /* BlocVM.swift in Sources */ = {isa = PBXBuildFile; fileRef = EC8F56A82A3BA6CB00BBD572 /* BlocVM.swift */; };
EC9CCD902A262137004D71A4 /* Test.swift in Sources */ = {isa = PBXBuildFile; fileRef = EC9CCD8F2A262137004D71A4 /* Test.swift */; };
ECA6FBAF2A208AF70023410A /* Bloc.swift in Sources */ = {isa = PBXBuildFile; fileRef = ECA6FBAE2A208AF70023410A /* Bloc.swift */; };
ECA6FBB12A209D060023410A /* ExUE.swift in Sources */ = {isa = PBXBuildFile; fileRef = ECA6FBB02A209D060023410A /* ExUE.swift */; };
ECA6FBB32A20B15B0023410A /* UEview.swift in Sources */ = {isa = PBXBuildFile; fileRef = ECA6FBB22A20B15B0023410A /* UEview.swift */; };
ECA6FBB62A20B3830023410A /* StubUE.swift in Sources */ = {isa = PBXBuildFile; fileRef = ECA6FBB52A20B3830023410A /* StubUE.swift */; };
ECA6FBB82A24CF140023410A /* MatiereView.swift in Sources */ = {isa = PBXBuildFile; fileRef = ECA6FBB72A24CF140023410A /* MatiereView.swift */; };
ECA6FBBA2A24CF3C0023410A /* StubMatiere.swift in Sources */ = {isa = PBXBuildFile; fileRef = ECA6FBB92A24CF3C0023410A /* StubMatiere.swift */; };
ECA6FBBC2A25D80B0023410A /* Maquette.swift in Sources */ = {isa = PBXBuildFile; fileRef = ECA6FBBB2A25D80B0023410A /* Maquette.swift */; };
ECA8F5C72A3359B20091291E /* MatieresVM.swift in Sources */ = {isa = PBXBuildFile; fileRef = ECA8F5C62A3359B20091291E /* MatieresVM.swift */; };
/* End PBXBuildFile section */
/* Begin PBXContainerItemProxy section */
EC48A2412A1CE01A008DB387 /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = EC48A2282A1CE019008DB387 /* Project object */;
proxyType = 1;
remoteGlobalIDString = EC48A22F2A1CE019008DB387;
remoteInfo = Calculator;
};
EC48A24B2A1CE01A008DB387 /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = EC48A2282A1CE019008DB387 /* Project object */;
proxyType = 1;
remoteGlobalIDString = EC48A22F2A1CE019008DB387;
remoteInfo = Calculator;
};
/* End PBXContainerItemProxy section */
/* Begin PBXFileReference section */
EC281BBE2A4523CD00AAA912 /* BlocItem.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BlocItem.swift; sourceTree = "<group>"; };
EC48A2302A1CE019008DB387 /* Calculator.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Calculator.app; sourceTree = BUILT_PRODUCTS_DIR; };
EC48A2332A1CE019008DB387 /* CalculatorApp.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CalculatorApp.swift; sourceTree = "<group>"; };
EC48A2352A1CE019008DB387 /* ContentView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ContentView.swift; sourceTree = "<group>"; };
EC48A2372A1CE01A008DB387 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = "<group>"; };
EC48A23A2A1CE01A008DB387 /* Preview Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = "Preview Assets.xcassets"; sourceTree = "<group>"; };
EC48A2402A1CE01A008DB387 /* CalculatorTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = CalculatorTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
EC48A2442A1CE01A008DB387 /* CalculatorTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CalculatorTests.swift; sourceTree = "<group>"; };
EC48A24A2A1CE01A008DB387 /* CalculatorUITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = CalculatorUITests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
EC48A24E2A1CE01A008DB387 /* CalculatorUITests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CalculatorUITests.swift; sourceTree = "<group>"; };
EC48A2502A1CE01A008DB387 /* CalculatorUITestsLaunchTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CalculatorUITestsLaunchTests.swift; sourceTree = "<group>"; };
EC48A25E2A1CFDE8008DB387 /* Matieres.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Matieres.swift; sourceTree = "<group>"; };
EC48A2602A1CFEC7008DB387 /* UE.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = UE.swift; sourceTree = "<group>"; };
EC48A2632A1D0214008DB387 /* HomeView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = HomeView.swift; sourceTree = "<group>"; };
EC48A26A2A1D10A0008DB387 /* EditView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = EditView.swift; sourceTree = "<group>"; };
EC5D85452A41AD0F00BBB920 /* Editpage.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Editpage.swift; sourceTree = "<group>"; };
EC5D85492A41BBB700BBB920 /* Manager.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Manager.swift; sourceTree = "<group>"; };
EC5D854B2A41BBDD00BBB920 /* DataManager.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DataManager.swift; sourceTree = "<group>"; };
EC5D854F2A41D17100BBB920 /* EditMatView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = EditMatView.swift; sourceTree = "<group>"; };
EC5D85512A41E4F900BBB920 /* BlocView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BlocView.swift; sourceTree = "<group>"; };
EC5D85532A41F13100BBB920 /* ManagerVM.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ManagerVM.swift; sourceTree = "<group>"; };
EC5D85552A43190300BBB920 /* AddMat.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AddMat.swift; sourceTree = "<group>"; };
EC8F56A42A39920700BBD572 /* UeVM.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = UeVM.swift; sourceTree = "<group>"; };
EC8F56A62A399CC600BBD572 /* ArrayExtension.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ArrayExtension.swift; sourceTree = "<group>"; };
EC8F56A82A3BA6CB00BBD572 /* BlocVM.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BlocVM.swift; sourceTree = "<group>"; };
EC9CCD8F2A262137004D71A4 /* Test.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Test.swift; sourceTree = "<group>"; };
ECA6FBAE2A208AF70023410A /* Bloc.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Bloc.swift; sourceTree = "<group>"; };
ECA6FBB02A209D060023410A /* ExUE.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ExUE.swift; sourceTree = "<group>"; };
ECA6FBB22A20B15B0023410A /* UEview.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = UEview.swift; sourceTree = "<group>"; };
ECA6FBB52A20B3830023410A /* StubUE.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = StubUE.swift; sourceTree = "<group>"; };
ECA6FBB72A24CF140023410A /* MatiereView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MatiereView.swift; sourceTree = "<group>"; };
ECA6FBB92A24CF3C0023410A /* StubMatiere.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = StubMatiere.swift; sourceTree = "<group>"; };
ECA6FBBB2A25D80B0023410A /* Maquette.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Maquette.swift; sourceTree = "<group>"; };
ECA8F5C62A3359B20091291E /* MatieresVM.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MatieresVM.swift; sourceTree = "<group>"; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
EC48A22D2A1CE019008DB387 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
};
EC48A23D2A1CE01A008DB387 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
};
EC48A2472A1CE01A008DB387 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXFrameworksBuildPhase section */
/* Begin PBXGroup section */
EC48A2272A1CE019008DB387 = {
isa = PBXGroup;
children = (
EC48A2322A1CE019008DB387 /* Calculator */,
EC48A2432A1CE01A008DB387 /* CalculatorTests */,
EC48A24D2A1CE01A008DB387 /* CalculatorUITests */,
EC48A2312A1CE019008DB387 /* Products */,
);
sourceTree = "<group>";
};
EC48A2312A1CE019008DB387 /* Products */ = {
isa = PBXGroup;
children = (
EC48A2302A1CE019008DB387 /* Calculator.app */,
EC48A2402A1CE01A008DB387 /* CalculatorTests.xctest */,
EC48A24A2A1CE01A008DB387 /* CalculatorUITests.xctest */,
);
name = Products;
sourceTree = "<group>";
};
EC48A2322A1CE019008DB387 /* Calculator */ = {
isa = PBXGroup;
children = (
ECA6FBB42A20B3730023410A /* Data */,
EC48A2672A1D0775008DB387 /* ViewModel */,
EC48A2622A1D01F8008DB387 /* View */,
EC48A25D2A1CFDC3008DB387 /* Model */,
EC48A2332A1CE019008DB387 /* CalculatorApp.swift */,
EC48A2352A1CE019008DB387 /* ContentView.swift */,
EC48A2372A1CE01A008DB387 /* Assets.xcassets */,
EC48A2392A1CE01A008DB387 /* Preview Content */,
);
path = Calculator;
sourceTree = "<group>";
};
EC48A2392A1CE01A008DB387 /* Preview Content */ = {
isa = PBXGroup;
children = (
EC48A23A2A1CE01A008DB387 /* Preview Assets.xcassets */,
);
path = "Preview Content";
sourceTree = "<group>";
};
EC48A2432A1CE01A008DB387 /* CalculatorTests */ = {
isa = PBXGroup;
children = (
EC48A2442A1CE01A008DB387 /* CalculatorTests.swift */,
);
path = CalculatorTests;
sourceTree = "<group>";
};
EC48A24D2A1CE01A008DB387 /* CalculatorUITests */ = {
isa = PBXGroup;
children = (
EC48A24E2A1CE01A008DB387 /* CalculatorUITests.swift */,
EC48A2502A1CE01A008DB387 /* CalculatorUITestsLaunchTests.swift */,
);
path = CalculatorUITests;
sourceTree = "<group>";
};
EC48A25D2A1CFDC3008DB387 /* Model */ = {
isa = PBXGroup;
children = (
EC48A25E2A1CFDE8008DB387 /* Matieres.swift */,
EC48A2602A1CFEC7008DB387 /* UE.swift */,
ECA6FBAE2A208AF70023410A /* Bloc.swift */,
ECA6FBB02A209D060023410A /* ExUE.swift */,
ECA6FBBB2A25D80B0023410A /* Maquette.swift */,
EC5D85492A41BBB700BBB920 /* Manager.swift */,
);
path = Model;
sourceTree = "<group>";
};
EC48A2622A1D01F8008DB387 /* View */ = {
isa = PBXGroup;
children = (
EC48A2632A1D0214008DB387 /* HomeView.swift */,
EC48A26A2A1D10A0008DB387 /* EditView.swift */,
ECA6FBB22A20B15B0023410A /* UEview.swift */,
ECA6FBB72A24CF140023410A /* MatiereView.swift */,
EC9CCD8F2A262137004D71A4 /* Test.swift */,
EC5D85452A41AD0F00BBB920 /* Editpage.swift */,
EC5D854F2A41D17100BBB920 /* EditMatView.swift */,
EC5D85512A41E4F900BBB920 /* BlocView.swift */,
EC5D85552A43190300BBB920 /* AddMat.swift */,
EC281BBE2A4523CD00AAA912 /* BlocItem.swift */,
);
path = View;
sourceTree = "<group>";
};
EC48A2672A1D0775008DB387 /* ViewModel */ = {
isa = PBXGroup;
children = (
ECA8F5C62A3359B20091291E /* MatieresVM.swift */,
EC8F56A42A39920700BBD572 /* UeVM.swift */,
EC8F56A82A3BA6CB00BBD572 /* BlocVM.swift */,
EC5D85532A41F13100BBB920 /* ManagerVM.swift */,
EC8F56A62A399CC600BBD572 /* ArrayExtension.swift */,
);
path = ViewModel;
sourceTree = "<group>";
};
ECA6FBB42A20B3730023410A /* Data */ = {
isa = PBXGroup;
children = (
ECA6FBB52A20B3830023410A /* StubUE.swift */,
ECA6FBB92A24CF3C0023410A /* StubMatiere.swift */,
EC5D854B2A41BBDD00BBB920 /* DataManager.swift */,
);
path = Data;
sourceTree = "<group>";
};
/* End PBXGroup section */
/* Begin PBXNativeTarget section */
EC48A22F2A1CE019008DB387 /* Calculator */ = {
isa = PBXNativeTarget;
buildConfigurationList = EC48A2542A1CE01A008DB387 /* Build configuration list for PBXNativeTarget "Calculator" */;
buildPhases = (
EC48A22C2A1CE019008DB387 /* Sources */,
EC48A22D2A1CE019008DB387 /* Frameworks */,
EC48A22E2A1CE019008DB387 /* Resources */,
);
buildRules = (
);
dependencies = (
);
name = Calculator;
productName = Calculator;
productReference = EC48A2302A1CE019008DB387 /* Calculator.app */;
productType = "com.apple.product-type.application";
};
EC48A23F2A1CE01A008DB387 /* CalculatorTests */ = {
isa = PBXNativeTarget;
buildConfigurationList = EC48A2572A1CE01A008DB387 /* Build configuration list for PBXNativeTarget "CalculatorTests" */;
buildPhases = (
EC48A23C2A1CE01A008DB387 /* Sources */,
EC48A23D2A1CE01A008DB387 /* Frameworks */,
EC48A23E2A1CE01A008DB387 /* Resources */,
);
buildRules = (
);
dependencies = (
EC48A2422A1CE01A008DB387 /* PBXTargetDependency */,
);
name = CalculatorTests;
productName = CalculatorTests;
productReference = EC48A2402A1CE01A008DB387 /* CalculatorTests.xctest */;
productType = "com.apple.product-type.bundle.unit-test";
};
EC48A2492A1CE01A008DB387 /* CalculatorUITests */ = {
isa = PBXNativeTarget;
buildConfigurationList = EC48A25A2A1CE01A008DB387 /* Build configuration list for PBXNativeTarget "CalculatorUITests" */;
buildPhases = (
EC48A2462A1CE01A008DB387 /* Sources */,
EC48A2472A1CE01A008DB387 /* Frameworks */,
EC48A2482A1CE01A008DB387 /* Resources */,
);
buildRules = (
);
dependencies = (
EC48A24C2A1CE01A008DB387 /* PBXTargetDependency */,
);
name = CalculatorUITests;
productName = CalculatorUITests;
productReference = EC48A24A2A1CE01A008DB387 /* CalculatorUITests.xctest */;
productType = "com.apple.product-type.bundle.ui-testing";
};
/* End PBXNativeTarget section */
/* Begin PBXProject section */
EC48A2282A1CE019008DB387 /* Project object */ = {
isa = PBXProject;
attributes = {
BuildIndependentTargetsInParallel = 1;
LastSwiftUpdateCheck = 1430;
LastUpgradeCheck = 1430;
TargetAttributes = {
EC48A22F2A1CE019008DB387 = {
CreatedOnToolsVersion = 14.3;
};
EC48A23F2A1CE01A008DB387 = {
CreatedOnToolsVersion = 14.3;
TestTargetID = EC48A22F2A1CE019008DB387;
};
EC48A2492A1CE01A008DB387 = {
CreatedOnToolsVersion = 14.3;
TestTargetID = EC48A22F2A1CE019008DB387;
};
};
};
buildConfigurationList = EC48A22B2A1CE019008DB387 /* Build configuration list for PBXProject "Calculator" */;
compatibilityVersion = "Xcode 14.0";
developmentRegion = en;
hasScannedForEncodings = 0;
knownRegions = (
en,
Base,
);
mainGroup = EC48A2272A1CE019008DB387;
productRefGroup = EC48A2312A1CE019008DB387 /* Products */;
projectDirPath = "";
projectRoot = "";
targets = (
EC48A22F2A1CE019008DB387 /* Calculator */,
EC48A23F2A1CE01A008DB387 /* CalculatorTests */,
EC48A2492A1CE01A008DB387 /* CalculatorUITests */,
);
};
/* End PBXProject section */
/* Begin PBXResourcesBuildPhase section */
EC48A22E2A1CE019008DB387 /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
EC48A23B2A1CE01A008DB387 /* Preview Assets.xcassets in Resources */,
EC48A2382A1CE01A008DB387 /* Assets.xcassets in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
EC48A23E2A1CE01A008DB387 /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
};
EC48A2482A1CE01A008DB387 /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXResourcesBuildPhase section */
/* Begin PBXSourcesBuildPhase section */
EC48A22C2A1CE019008DB387 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
EC48A2362A1CE019008DB387 /* ContentView.swift in Sources */,
EC48A25F2A1CFDE8008DB387 /* Matieres.swift in Sources */,
EC9CCD902A262137004D71A4 /* Test.swift in Sources */,
EC8F56A72A399CC600BBD572 /* ArrayExtension.swift in Sources */,
EC5D85522A41E4F900BBB920 /* BlocView.swift in Sources */,
EC5D854A2A41BBB700BBB920 /* Manager.swift in Sources */,
ECA6FBB12A209D060023410A /* ExUE.swift in Sources */,
EC48A2342A1CE019008DB387 /* CalculatorApp.swift in Sources */,
EC8F56A92A3BA6CB00BBD572 /* BlocVM.swift in Sources */,
EC48A26B2A1D10A0008DB387 /* EditView.swift in Sources */,
EC8F56A52A39920700BBD572 /* UeVM.swift in Sources */,
ECA6FBBC2A25D80B0023410A /* Maquette.swift in Sources */,
EC5D85502A41D17100BBB920 /* EditMatView.swift in Sources */,
EC5D85562A43190300BBB920 /* AddMat.swift in Sources */,
ECA8F5C72A3359B20091291E /* MatieresVM.swift in Sources */,
ECA6FBB82A24CF140023410A /* MatiereView.swift in Sources */,
EC48A2642A1D0214008DB387 /* HomeView.swift in Sources */,
EC5D85542A41F13100BBB920 /* ManagerVM.swift in Sources */,
ECA6FBB62A20B3830023410A /* StubUE.swift in Sources */,
ECA6FBAF2A208AF70023410A /* Bloc.swift in Sources */,
EC5D85462A41AD0F00BBB920 /* Editpage.swift in Sources */,
ECA6FBB32A20B15B0023410A /* UEview.swift in Sources */,
EC5D854C2A41BBDD00BBB920 /* DataManager.swift in Sources */,
ECA6FBBA2A24CF3C0023410A /* StubMatiere.swift in Sources */,
EC281BBF2A4523CD00AAA912 /* BlocItem.swift in Sources */,
EC48A2612A1CFEC7008DB387 /* UE.swift in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
EC48A23C2A1CE01A008DB387 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
EC48A2452A1CE01A008DB387 /* CalculatorTests.swift in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
EC48A2462A1CE01A008DB387 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
EC48A2512A1CE01A008DB387 /* CalculatorUITestsLaunchTests.swift in Sources */,
EC48A24F2A1CE01A008DB387 /* CalculatorUITests.swift in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXSourcesBuildPhase section */
/* Begin PBXTargetDependency section */
EC48A2422A1CE01A008DB387 /* PBXTargetDependency */ = {
isa = PBXTargetDependency;
target = EC48A22F2A1CE019008DB387 /* Calculator */;
targetProxy = EC48A2412A1CE01A008DB387 /* PBXContainerItemProxy */;
};
EC48A24C2A1CE01A008DB387 /* PBXTargetDependency */ = {
isa = PBXTargetDependency;
target = EC48A22F2A1CE019008DB387 /* Calculator */;
targetProxy = EC48A24B2A1CE01A008DB387 /* PBXContainerItemProxy */;
};
/* End PBXTargetDependency section */
/* Begin XCBuildConfiguration section */
EC48A2522A1CE01A008DB387 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ANALYZER_NONNULL = YES;
CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++20";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_ENABLE_OBJC_WEAK = YES;
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
COPY_PHASE_STRIP = NO;
DEBUG_INFORMATION_FORMAT = dwarf;
ENABLE_STRICT_OBJC_MSGSEND = YES;
ENABLE_TESTABILITY = YES;
GCC_C_LANGUAGE_STANDARD = gnu11;
GCC_DYNAMIC_NO_PIC = NO;
GCC_NO_COMMON_BLOCKS = YES;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PREPROCESSOR_DEFINITIONS = (
"DEBUG=1",
"$(inherited)",
);
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 16.4;
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
MTL_FAST_MATH = YES;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG;
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
};
name = Debug;
};
EC48A2532A1CE01A008DB387 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ANALYZER_NONNULL = YES;
CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++20";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_ENABLE_OBJC_WEAK = YES;
CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_COMMA = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INFINITE_RECURSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES;
CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
CLANG_WARN_STRICT_PROTOTYPES = YES;
CLANG_WARN_SUSPICIOUS_MOVE = YES;
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
COPY_PHASE_STRIP = NO;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
ENABLE_NS_ASSERTIONS = NO;
ENABLE_STRICT_OBJC_MSGSEND = YES;
GCC_C_LANGUAGE_STANDARD = gnu11;
GCC_NO_COMMON_BLOCKS = YES;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 16.4;
MTL_ENABLE_DEBUG_INFO = NO;
MTL_FAST_MATH = YES;
SDKROOT = iphoneos;
SWIFT_COMPILATION_MODE = wholemodule;
SWIFT_OPTIMIZATION_LEVEL = "-O";
VALIDATE_PRODUCT = YES;
};
name = Release;
};
EC48A2552A1CE01A008DB387 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 1;
DEVELOPMENT_ASSET_PATHS = "\"Calculator/Preview Content\"";
ENABLE_PREVIEWS = YES;
GENERATE_INFOPLIST_FILE = YES;
INFOPLIST_KEY_UIApplicationSceneManifest_Generation = YES;
INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES;
INFOPLIST_KEY_UILaunchScreen_Generation = YES;
INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight";
INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight";
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 1.0;
PRODUCT_BUNDLE_IDENTIFIER = fr.uca.iut.Calculator;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_EMIT_LOC_STRINGS = YES;
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
};
name = Debug;
};
EC48A2562A1CE01A008DB387 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 1;
DEVELOPMENT_ASSET_PATHS = "\"Calculator/Preview Content\"";
ENABLE_PREVIEWS = YES;
GENERATE_INFOPLIST_FILE = YES;
INFOPLIST_KEY_UIApplicationSceneManifest_Generation = YES;
INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES;
INFOPLIST_KEY_UILaunchScreen_Generation = YES;
INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight";
INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight";
LD_RUNPATH_SEARCH_PATHS = (
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 1.0;
PRODUCT_BUNDLE_IDENTIFIER = fr.uca.iut.Calculator;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_EMIT_LOC_STRINGS = YES;
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
};
name = Release;
};
EC48A2582A1CE01A008DB387 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES;
BUNDLE_LOADER = "$(TEST_HOST)";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 1;
GENERATE_INFOPLIST_FILE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 16.4;
MARKETING_VERSION = 1.0;
PRODUCT_BUNDLE_IDENTIFIER = fr.uca.iut.CalculatorTests;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_EMIT_LOC_STRINGS = NO;
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
TEST_HOST = "$(BUILT_PRODUCTS_DIR)/Calculator.app/$(BUNDLE_EXECUTABLE_FOLDER_PATH)/Calculator";
};
name = Debug;
};
EC48A2592A1CE01A008DB387 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES;
BUNDLE_LOADER = "$(TEST_HOST)";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 1;
GENERATE_INFOPLIST_FILE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 16.4;
MARKETING_VERSION = 1.0;
PRODUCT_BUNDLE_IDENTIFIER = fr.uca.iut.CalculatorTests;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_EMIT_LOC_STRINGS = NO;
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
TEST_HOST = "$(BUILT_PRODUCTS_DIR)/Calculator.app/$(BUNDLE_EXECUTABLE_FOLDER_PATH)/Calculator";
};
name = Release;
};
EC48A25B2A1CE01A008DB387 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES;
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 1;
GENERATE_INFOPLIST_FILE = YES;
MARKETING_VERSION = 1.0;
PRODUCT_BUNDLE_IDENTIFIER = fr.uca.iut.CalculatorUITests;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_EMIT_LOC_STRINGS = NO;
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
TEST_TARGET_NAME = Calculator;
};
name = Debug;
};
EC48A25C2A1CE01A008DB387 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES;
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 1;
GENERATE_INFOPLIST_FILE = YES;
MARKETING_VERSION = 1.0;
PRODUCT_BUNDLE_IDENTIFIER = fr.uca.iut.CalculatorUITests;
PRODUCT_NAME = "$(TARGET_NAME)";
SWIFT_EMIT_LOC_STRINGS = NO;
SWIFT_VERSION = 5.0;
TARGETED_DEVICE_FAMILY = "1,2";
TEST_TARGET_NAME = Calculator;
};
name = Release;
};
/* End XCBuildConfiguration section */
/* Begin XCConfigurationList section */
EC48A22B2A1CE019008DB387 /* Build configuration list for PBXProject "Calculator" */ = {
isa = XCConfigurationList;
buildConfigurations = (
EC48A2522A1CE01A008DB387 /* Debug */,
EC48A2532A1CE01A008DB387 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
EC48A2542A1CE01A008DB387 /* Build configuration list for PBXNativeTarget "Calculator" */ = {
isa = XCConfigurationList;
buildConfigurations = (
EC48A2552A1CE01A008DB387 /* Debug */,
EC48A2562A1CE01A008DB387 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
EC48A2572A1CE01A008DB387 /* Build configuration list for PBXNativeTarget "CalculatorTests" */ = {
isa = XCConfigurationList;
buildConfigurations = (
EC48A2582A1CE01A008DB387 /* Debug */,
EC48A2592A1CE01A008DB387 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
EC48A25A2A1CE01A008DB387 /* Build configuration list for PBXNativeTarget "CalculatorUITests" */ = {
isa = XCConfigurationList;
buildConfigurations = (
EC48A25B2A1CE01A008DB387 /* Debug */,
EC48A25C2A1CE01A008DB387 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
/* End XCConfigurationList section */
};
rootObject = EC48A2282A1CE019008DB387 /* Project object */;
}

@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<Workspace
version = "1.0">
<FileRef
location = "self:">
</FileRef>
</Workspace>

@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>IDEDidComputeMac32BitWarning</key>
<true/>
</dict>
</plist>

@ -0,0 +1,120 @@
<?xml version="1.0" encoding="UTF-8"?>
<Bucket
uuid = "ED4983DD-7975-450D-A1BD-F1EB553EEAD9"
type = "1"
version = "2.0">
<Breakpoints>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
uuid = "E16FCD8F-A2F7-4EE5-9A30-FF6BEB352401"
shouldBeEnabled = "Yes"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "Calculator/View/EditView.swift"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "4"
endingLineNumber = "4"
landmarkName = "unknown"
landmarkType = "0">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
uuid = "74C87335-F616-47DA-BB6C-176CFA33C2E7"
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "Calculator/View/BlocView.swift"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "43"
endingLineNumber = "43"
landmarkName = "body"
landmarkType = "24">
<Locations>
<Location
uuid = "74C87335-F616-47DA-BB6C-176CFA33C2E7 - ff6055684619a3c4"
shouldBeEnabled = "Yes"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "closure #3 () -&gt; SwiftUI.TupleView&lt;(&lt;&lt;opaque return type of SwiftUI.View.foregroundColor(Swift.Optional&lt;SwiftUI.Color&gt;) -&gt; some&gt;&gt;.0, SwiftUI.Text, SwiftUI.Spacer, SwiftUI.Text, SwiftUI.Image)&gt; in closure #1 () -&gt; SwiftUI.TupleView&lt;(SwiftUI.HStack&lt;SwiftUI.TupleView&lt;(&lt;&lt;opaque return type of SwiftUI.View.foregroundColor(Swift.Optional&lt;SwiftUI.Color&gt;) -&gt; some&gt;&gt;.0, SwiftUI.Text)&gt;&gt;, SwiftUI.VStack&lt;&lt;&lt;opaque return type of SwiftUI.View.padding(SwiftUI.Edge.Set, Swift.Optional&lt;CoreGraphics.CGFloat&gt;) -&gt; some&gt;&gt;.0&gt;, SwiftUI.HStack&lt;SwiftUI.TupleView&lt;(&lt;&lt;opaque return type of SwiftUI.View.foregroundColor(Swift.Optional&lt;SwiftUI.Color&gt;) -&gt; some&gt;&gt;.0, SwiftUI.Text, SwiftUI.Spacer, SwiftUI.Text, SwiftUI.Image)&gt;&gt;, SwiftUI.HStack&lt;SwiftUI.TupleView&lt;(&lt;&lt;opaque return type of SwiftUI.View.foregroundColor(Swift.Optional&lt;SwiftUI.Color&gt;) -&gt; some&gt;&gt;.0, SwiftUI.Text, SwiftUI.Spacer, SwiftUI.Text, SwiftUI.Image)&gt;&gt;)&gt; in closure #1 () -&gt; SwiftUI.TupleView&lt;(&lt;&lt;opaque return type of SwiftUI.View.padding(SwiftUI.Edge.Set, Swift.Optional&lt;CoreGraphics.CGFloat&gt;) -&gt; some&gt;&gt;.0, &lt;&lt;opaque return type of SwiftUI.View.overlay&lt;&#x3c4;_0_0 where &#x3c4;_1_0: SwiftUI.View&gt;(_: &#x3c4;_1_0, alignment: SwiftUI.Alignment) -&gt; some&gt;&gt;.0)&gt; in closure #1 () -&gt; SwiftUI.VStack&lt;SwiftUI.TupleView&lt;(&lt;&lt;opaque return type of SwiftUI.View.padding(SwiftUI.Edge.Set, Swift.Optional&lt;CoreGraphics.CGFloat&gt;) -&gt; some&gt;&gt;.0, &lt;&lt;opaque return type of SwiftUI.View.overlay&lt;&#x3c4;_0_0 where &#x3c4;_1_0: SwiftUI.View&gt;(_: &#x3c4;_1_0, alignment: SwiftUI.Alignment) -&gt; some&gt;&gt;.0)&gt;&gt; in closure #1 () -&gt; SwiftUI.ZStack&lt;SwiftUI.VStack&lt;SwiftUI.TupleView&lt;(&lt;&lt;opaque return type of SwiftUI.View.padding(SwiftUI.Edge.Set, Swift.Optional&lt;CoreGraphics.CGFloat&gt;) -&gt; some&gt;&gt;.0, &lt;&lt;opaque return type of SwiftUI.View.overlay&lt;&#x3c4;_0_0 where &#x3c4;_1_0: SwiftUI.View&gt;(_: &#x3c4;_1_0, alignment: SwiftUI.Alignment) -&gt; some&gt;&gt;.0)&gt;&gt;&gt; in Calculator.BlocView.body.getter : some"
moduleName = "Calculator"
usesParentBreakpointCondition = "Yes"
urlString = "file:///Users/etudiant/Projects/Calculator/Calculator/View/BlocView.swift"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "41"
endingLineNumber = "41"
offsetFromSymbolStart = "780">
</Location>
<Location
uuid = "74C87335-F616-47DA-BB6C-176CFA33C2E7 - ff6055684619a363"
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "closure #3 () -&gt; SwiftUI.TupleView&lt;(&lt;&lt;opaque return type of SwiftUI.View.foregroundColor(Swift.Optional&lt;SwiftUI.Color&gt;) -&gt; some&gt;&gt;.0, SwiftUI.Text, SwiftUI.Spacer, SwiftUI.Text, SwiftUI.Image)&gt; in closure #1 () -&gt; SwiftUI.TupleView&lt;(SwiftUI.HStack&lt;SwiftUI.TupleView&lt;(&lt;&lt;opaque return type of SwiftUI.View.foregroundColor(Swift.Optional&lt;SwiftUI.Color&gt;) -&gt; some&gt;&gt;.0, SwiftUI.Text)&gt;&gt;, SwiftUI.VStack&lt;&lt;&lt;opaque return type of SwiftUI.View.padding(SwiftUI.Edge.Set, Swift.Optional&lt;CoreGraphics.CGFloat&gt;) -&gt; some&gt;&gt;.0&gt;, SwiftUI.HStack&lt;SwiftUI.TupleView&lt;(&lt;&lt;opaque return type of SwiftUI.View.foregroundColor(Swift.Optional&lt;SwiftUI.Color&gt;) -&gt; some&gt;&gt;.0, SwiftUI.Text, SwiftUI.Spacer, SwiftUI.Text, SwiftUI.Image)&gt;&gt;, SwiftUI.HStack&lt;SwiftUI.TupleView&lt;(&lt;&lt;opaque return type of SwiftUI.View.foregroundColor(Swift.Optional&lt;SwiftUI.Color&gt;) -&gt; some&gt;&gt;.0, SwiftUI.Text, SwiftUI.Spacer, SwiftUI.Text, SwiftUI.Image)&gt;&gt;)&gt; in closure #1 () -&gt; SwiftUI.TupleView&lt;(&lt;&lt;opaque return type of SwiftUI.View.padding(SwiftUI.Edge.Set, Swift.Optional&lt;CoreGraphics.CGFloat&gt;) -&gt; some&gt;&gt;.0, &lt;&lt;opaque return type of SwiftUI.View.overlay&lt;&#x3c4;_0_0 where &#x3c4;_1_0: SwiftUI.View&gt;(_: &#x3c4;_1_0, alignment: SwiftUI.Alignment) -&gt; some&gt;&gt;.0)&gt; in closure #1 () -&gt; SwiftUI.VStack&lt;SwiftUI.TupleView&lt;(&lt;&lt;opaque return type of SwiftUI.View.padding(SwiftUI.Edge.Set, Swift.Optional&lt;CoreGraphics.CGFloat&gt;) -&gt; some&gt;&gt;.0, &lt;&lt;opaque return type of SwiftUI.View.overlay&lt;&#x3c4;_0_0 where &#x3c4;_1_0: SwiftUI.View&gt;(_: &#x3c4;_1_0, alignment: SwiftUI.Alignment) -&gt; some&gt;&gt;.0)&gt;&gt; in closure #1 () -&gt; SwiftUI.ZStack&lt;SwiftUI.VStack&lt;SwiftUI.TupleView&lt;(&lt;&lt;opaque return type of SwiftUI.View.padding(SwiftUI.Edge.Set, Swift.Optional&lt;CoreGraphics.CGFloat&gt;) -&gt; some&gt;&gt;.0, &lt;&lt;opaque return type of SwiftUI.View.overlay&lt;&#x3c4;_0_0 where &#x3c4;_1_0: SwiftUI.View&gt;(_: &#x3c4;_1_0, alignment: SwiftUI.Alignment) -&gt; some&gt;&gt;.0)&gt;&gt;&gt; in Calculator.BlocView.body.getter : some"
moduleName = "Calculator"
usesParentBreakpointCondition = "Yes"
urlString = "file:///Users/etudiant/Projects/Calculator/Calculator/View/BlocView.swift"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "44"
endingLineNumber = "44"
offsetFromSymbolStart = "1776">
</Location>
</Locations>
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
uuid = "B3237572-CD49-4FF0-AD3D-D7931E93EA4D"
shouldBeEnabled = "No"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "Calculator/View/BlocView.swift"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "42"
endingLineNumber = "42"
landmarkName = "body"
landmarkType = "24">
<Locations>
<Location
uuid = "B3237572-CD49-4FF0-AD3D-D7931E93EA4D - ff6055684619a3e7"
shouldBeEnabled = "Yes"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "closure #3 () -&gt; SwiftUI.TupleView&lt;(&lt;&lt;opaque return type of SwiftUI.View.foregroundColor(Swift.Optional&lt;SwiftUI.Color&gt;) -&gt; some&gt;&gt;.0, SwiftUI.Text, SwiftUI.Spacer, SwiftUI.Text, SwiftUI.Image)&gt; in closure #1 () -&gt; SwiftUI.TupleView&lt;(SwiftUI.HStack&lt;SwiftUI.TupleView&lt;(&lt;&lt;opaque return type of SwiftUI.View.foregroundColor(Swift.Optional&lt;SwiftUI.Color&gt;) -&gt; some&gt;&gt;.0, SwiftUI.Text)&gt;&gt;, SwiftUI.VStack&lt;&lt;&lt;opaque return type of SwiftUI.View.padding(SwiftUI.Edge.Set, Swift.Optional&lt;CoreGraphics.CGFloat&gt;) -&gt; some&gt;&gt;.0&gt;, SwiftUI.HStack&lt;SwiftUI.TupleView&lt;(&lt;&lt;opaque return type of SwiftUI.View.foregroundColor(Swift.Optional&lt;SwiftUI.Color&gt;) -&gt; some&gt;&gt;.0, SwiftUI.Text, SwiftUI.Spacer, SwiftUI.Text, SwiftUI.Image)&gt;&gt;, SwiftUI.HStack&lt;SwiftUI.TupleView&lt;(&lt;&lt;opaque return type of SwiftUI.View.foregroundColor(Swift.Optional&lt;SwiftUI.Color&gt;) -&gt; some&gt;&gt;.0, SwiftUI.Text, SwiftUI.Spacer, SwiftUI.Text, SwiftUI.Image)&gt;&gt;)&gt; in closure #1 () -&gt; SwiftUI.TupleView&lt;(&lt;&lt;opaque return type of SwiftUI.View.padding(SwiftUI.Edge.Set, Swift.Optional&lt;CoreGraphics.CGFloat&gt;) -&gt; some&gt;&gt;.0, &lt;&lt;opaque return type of SwiftUI.View.overlay&lt;&#x3c4;_0_0 where &#x3c4;_1_0: SwiftUI.View&gt;(_: &#x3c4;_1_0, alignment: SwiftUI.Alignment) -&gt; some&gt;&gt;.0)&gt; in closure #1 () -&gt; SwiftUI.VStack&lt;SwiftUI.TupleView&lt;(&lt;&lt;opaque return type of SwiftUI.View.padding(SwiftUI.Edge.Set, Swift.Optional&lt;CoreGraphics.CGFloat&gt;) -&gt; some&gt;&gt;.0, &lt;&lt;opaque return type of SwiftUI.View.overlay&lt;&#x3c4;_0_0 where &#x3c4;_1_0: SwiftUI.View&gt;(_: &#x3c4;_1_0, alignment: SwiftUI.Alignment) -&gt; some&gt;&gt;.0)&gt;&gt; in closure #1 () -&gt; SwiftUI.ZStack&lt;SwiftUI.VStack&lt;SwiftUI.TupleView&lt;(&lt;&lt;opaque return type of SwiftUI.View.padding(SwiftUI.Edge.Set, Swift.Optional&lt;CoreGraphics.CGFloat&gt;) -&gt; some&gt;&gt;.0, &lt;&lt;opaque return type of SwiftUI.View.overlay&lt;&#x3c4;_0_0 where &#x3c4;_1_0: SwiftUI.View&gt;(_: &#x3c4;_1_0, alignment: SwiftUI.Alignment) -&gt; some&gt;&gt;.0)&gt;&gt;&gt; in Calculator.BlocView.body.getter : some"
moduleName = "Calculator"
usesParentBreakpointCondition = "Yes"
urlString = "file:///Users/etudiant/Projects/Calculator/Calculator/View/BlocView.swift"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "40"
endingLineNumber = "40"
offsetFromSymbolStart = "712">
</Location>
<Location
uuid = "B3237572-CD49-4FF0-AD3D-D7931E93EA4D - ff6055684619a3a5"
shouldBeEnabled = "Yes"
ignoreCount = "0"
continueAfterRunningActions = "No"
symbolName = "closure #3 () -&gt; SwiftUI.TupleView&lt;(&lt;&lt;opaque return type of SwiftUI.View.foregroundColor(Swift.Optional&lt;SwiftUI.Color&gt;) -&gt; some&gt;&gt;.0, SwiftUI.Text, SwiftUI.Spacer, SwiftUI.Text, SwiftUI.Image)&gt; in closure #1 () -&gt; SwiftUI.TupleView&lt;(SwiftUI.HStack&lt;SwiftUI.TupleView&lt;(&lt;&lt;opaque return type of SwiftUI.View.foregroundColor(Swift.Optional&lt;SwiftUI.Color&gt;) -&gt; some&gt;&gt;.0, SwiftUI.Text)&gt;&gt;, SwiftUI.VStack&lt;&lt;&lt;opaque return type of SwiftUI.View.padding(SwiftUI.Edge.Set, Swift.Optional&lt;CoreGraphics.CGFloat&gt;) -&gt; some&gt;&gt;.0&gt;, SwiftUI.HStack&lt;SwiftUI.TupleView&lt;(&lt;&lt;opaque return type of SwiftUI.View.foregroundColor(Swift.Optional&lt;SwiftUI.Color&gt;) -&gt; some&gt;&gt;.0, SwiftUI.Text, SwiftUI.Spacer, SwiftUI.Text, SwiftUI.Image)&gt;&gt;, SwiftUI.HStack&lt;SwiftUI.TupleView&lt;(&lt;&lt;opaque return type of SwiftUI.View.foregroundColor(Swift.Optional&lt;SwiftUI.Color&gt;) -&gt; some&gt;&gt;.0, SwiftUI.Text, SwiftUI.Spacer, SwiftUI.Text, SwiftUI.Image)&gt;&gt;)&gt; in closure #1 () -&gt; SwiftUI.TupleView&lt;(&lt;&lt;opaque return type of SwiftUI.View.padding(SwiftUI.Edge.Set, Swift.Optional&lt;CoreGraphics.CGFloat&gt;) -&gt; some&gt;&gt;.0, &lt;&lt;opaque return type of SwiftUI.View.overlay&lt;&#x3c4;_0_0 where &#x3c4;_1_0: SwiftUI.View&gt;(_: &#x3c4;_1_0, alignment: SwiftUI.Alignment) -&gt; some&gt;&gt;.0)&gt; in closure #1 () -&gt; SwiftUI.VStack&lt;SwiftUI.TupleView&lt;(&lt;&lt;opaque return type of SwiftUI.View.padding(SwiftUI.Edge.Set, Swift.Optional&lt;CoreGraphics.CGFloat&gt;) -&gt; some&gt;&gt;.0, &lt;&lt;opaque return type of SwiftUI.View.overlay&lt;&#x3c4;_0_0 where &#x3c4;_1_0: SwiftUI.View&gt;(_: &#x3c4;_1_0, alignment: SwiftUI.Alignment) -&gt; some&gt;&gt;.0)&gt;&gt; in closure #1 () -&gt; SwiftUI.ZStack&lt;SwiftUI.VStack&lt;SwiftUI.TupleView&lt;(&lt;&lt;opaque return type of SwiftUI.View.padding(SwiftUI.Edge.Set, Swift.Optional&lt;CoreGraphics.CGFloat&gt;) -&gt; some&gt;&gt;.0, &lt;&lt;opaque return type of SwiftUI.View.overlay&lt;&#x3c4;_0_0 where &#x3c4;_1_0: SwiftUI.View&gt;(_: &#x3c4;_1_0, alignment: SwiftUI.Alignment) -&gt; some&gt;&gt;.0)&gt;&gt;&gt; in Calculator.BlocView.body.getter : some"
moduleName = "Calculator"
usesParentBreakpointCondition = "Yes"
urlString = "file:///Users/etudiant/Projects/Calculator/Calculator/View/BlocView.swift"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "42"
endingLineNumber = "42"
offsetFromSymbolStart = "1280">
</Location>
</Locations>
</BreakpointContent>
</BreakpointProxy>
</Breakpoints>
</Bucket>

@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>SchemeUserState</key>
<dict>
<key>Calculator.xcscheme_^#shared#^_</key>
<dict>
<key>orderHint</key>
<integer>0</integer>
</dict>
</dict>
</dict>
</plist>

@ -0,0 +1,11 @@
{
"colors" : [
{
"idiom" : "universal"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}

@ -0,0 +1,13 @@
{
"images" : [
{
"idiom" : "universal",
"platform" : "ios",
"size" : "1024x1024"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}

@ -0,0 +1,6 @@
{
"info" : {
"author" : "xcode",
"version" : 1
}
}

@ -0,0 +1,23 @@
//
// CalculatorApp.swift
// Calculator
//
// Created by etudiant on 23/05/2023.
//
import SwiftUI
@main
struct CalculatorApp: App {
let ueViewModel = UeVM()
var blocs = [
BlocVM(withModel: Bloc(name: "Total", ListUE: StubUE().loadUEs(), isUq: false)),
BlocVM(withModel: Bloc(name: "Projet/Stage", ListUE: StubUE().loadUeStage_Proj(), isUq: true))
]
var body: some Scene {
WindowGroup {
HomeView(manager : ManagerVM(withBeds: blocs))
}
}
}

@ -0,0 +1,28 @@
//
// ContentView.swift
// Calculator
//
// Created by etudiant on 23/05/2023.
//
import SwiftUI
struct ContentView: View {
var body: some View {
VStack{
Text("skk")
}
}
}
struct ContentView_Previews: PreviewProvider {
static var previews: some View {
ContentView()
}
}

@ -0,0 +1,13 @@
//
// DataManager.swift
// Calculator
//
// Created by etudiant on 20/06/2023.
//
import Foundation
public protocol DataManager {
func loadUEs() -> [UE]
func loadUeStage_Proj() -> [UE]
func save(ues: [UE])
}

@ -0,0 +1,66 @@
//
// StubMatiere.swift
// Calculator
//
// Created by etudiant on 29/05/2023.
///Users/etudiant/Projects/Calculator/Calculator/View/HomeView.swift
import Foundation
struct StubMatiere {
func UE1()-> [Matieres] {
let Matieres1 = Matieres(name: "Processus de développement", note: 13.41, coef: 6)
let Matieres2 = Matieres( name: "Programmation Objets", note: 4.0, coef: 5)
let Matieres3 = Matieres( name: "Qualité de développement", note: 11.0, coef: 5)
let Matieres4 = Matieres( name: "Remise à niveau Objets", note: 8.0, coef: 5)
return [Matieres1, Matieres2,Matieres3,Matieres4]
}
func UE2()-> [Matieres] {
let Matieres1 = Matieres(name: "Internet des Objets ", note: 8.40, coef: 6)
let Matieres2 = Matieres( name: "Réseaux ", note: 4.0, coef: 5)
let Matieres3 = Matieres( name: "Services", note: 15.0, coef: 5)
let Matieres4 = Matieres( name: "Système", note: 8.0, coef: 5)
return [Matieres1, Matieres2,Matieres3,Matieres4]
}
func UE3()-> [Matieres] {
let Matieres1 = Matieres( name: "Anglais", note: 19.41, coef: 6)
let Matieres2 = Matieres( name: "Economie", note: 4.0, coef: 5)
let Matieres3 = Matieres(name: "Gestion", note: 16.0, coef: 5)
let Matieres4 = Matieres(name: "Communication", note: 8.0, coef: 5)
return [Matieres1, Matieres2,Matieres3,Matieres4]
}
func UE4()-> [Matieres] {
let Matieres1 = Matieres(name: "Android", note: 1.41, coef: 6)
let Matieres2 = Matieres( name: "Architecture de projets C# .NET (1)", note: 4.0, coef: 5)
let Matieres3 = Matieres( name: "C++", note: 19.0, coef: 5)
let Matieres4 = Matieres( name: "Swift", note: 8.0, coef: 5)
return [Matieres1, Matieres2,Matieres3,Matieres4]
}
func UE5()-> [Matieres] {
let Matieres1 = Matieres(name: "Architecture de projets C# .NET (2) ", note: 19.41, coef: 6)
let Matieres2 = Matieres( name: "Client/Serveur", note: 4.0, coef: 5)
let Matieres3 = Matieres( name: "iOS", note: 11.0, coef: 5)
let Matieres4 = Matieres(name: "Multiplateformes", note: 8.0, coef: 5)
let Matieres5 = Matieres( name: "QT Quick", note: 5.0, coef: 5)
let Matieres6 = Matieres( name: "Xamarin", note: 8.0, coef: 5)
return [Matieres1, Matieres2,Matieres3,Matieres4,Matieres5,Matieres6]
}
func UE6()-> [Matieres] {
let Matieres1 = Matieres( name: "Projet ", note: 10, coef: 9)
return [Matieres1]
}
func UE7()-> [Matieres] {
let Matieres1 = Matieres(name: "Stage ", note: 14, coef: 9)
return [Matieres1]
}
}

@ -0,0 +1,35 @@
//
// StubUE.swift
// Calculator
//
// Created by etudiant on 26/05/2023.
//
import Foundation
public struct StubUE : DataManager {
public func loadUeStage_Proj() -> [UE] {
return [
UE(name: "Projet", listMatiere: StubMatiere().UE6(), coef: 6),
UE(name: "Stage", listMatiere: StubMatiere().UE7(), coef: 6)
]
}
public func loadUEs()-> [UE]{
let ue1 = UE(name: "UE1 Génie logiciel", listMatiere: StubMatiere().UE1(), coef: 6)
let ue2 = UE(name: "UE2 Systèmes et réseaux", listMatiere: StubMatiere().UE2(), coef: 6)
let ue3 = UE(name: "UE3 Insertion Professionnelle", listMatiere:StubMatiere().UE3(), coef: 6)
let ue4 = UE(name: "UE4 Technologies Mobiles 1", listMatiere: StubMatiere().UE4(), coef: 9)
let ue5 = UE(name: "UE5 Technologies Mobiles 2", listMatiere: StubMatiere().UE5(), coef: 9)
let ue6 = UE(name: "UE6 Projet", listMatiere: StubMatiere().UE6(), coef: 9)
let ue7 = UE(name: "UE7 Stage", listMatiere: StubMatiere().UE7(), coef: 15)
return [ue1, ue2,ue3,ue4,ue5,ue6,ue7]
}
public func save(ues: [UE]) {
}
}

@ -0,0 +1,32 @@
//
// Bloc.swift
// Calculator
//
// Created by etudiant on 26/05/2023.
//
import Foundation
public struct Bloc: Identifiable,Equatable {
public static func == (lhs: Bloc, rhs: Bloc) -> Bool {
lhs.id == rhs.id
}
public let id: UUID
public var name: String
public var listUE: [UE]
public var isUnique : Bool
var total : Double {
return Double(listUE.reduce(0) { $0 + $1.generalNote }) / Double(listUE.count)
}
init(name: String, ListUE : [UE], isUq : Bool) {
self.id = UUID()
self.name = name
self.listUE = ListUE
self.isUnique = isUq
}
}

@ -0,0 +1,63 @@
//
// ExUE.swift
// Calculator
//
// Created by etudiant on 26/05/2023.
//
import Foundation
extension UE {
struct Data: Identifiable{
public let id: UUID
public var name: String
public var coef : Int
public var listMatiere: [Matieres]
var generalNote: Double {
return Double(listMatiere.reduce(into: 0) { $0 + $1.note }) / Double(listMatiere.count)
}
}
var data : Data {
Data(
id : self.id,
name:self.name,
coef:self.coef ,
listMatiere : self.listMatiere)
}
mutating func update(from data : Data){
guard data.id == self.id else {return}
self.name = data.name
self.coef = data.coef
self.listMatiere = data.listMatiere
}
}
class ExUE : ObservableObject{
var original : UE
@Published var model : UE.Data
@Published var isEditing : Bool = false
init(withUe ue : UE) {
self.original = ue
self.model = original.data
}
func onEditing(){
model = original.data
isEditing = true
}
func onEdited(isCancelled : Bool = false){
if(!isCancelled){
original.update(from: model)
}
isEditing = false
model = original.data
}
}

@ -0,0 +1,12 @@
//
// UEs.swift
// Calculator
//
// Created by etudiant on 23/05/2023.
//
import Foundation
struct Item: Identifiable,Equatable {
let id = UUID()
let name: String
}

@ -0,0 +1,27 @@
//
// Manager.swift
// Calculator
//
// Created by etudiant on 20/06/2023.
//
import Foundation
public struct Manager {
let dataManager: DataManager
public var ues: [UE] = []
public init(withDataManager dataManager: DataManager){
self.dataManager = dataManager
}
public mutating func loadUes() {
self.ues.removeAll()
for ue in self.dataManager.loadUEs() {
self.ues.append(ue)
}
}
public func saveUes() {
self.dataManager.save(ues:self.ues)
}
}

@ -0,0 +1,19 @@
//
// Maquette.swift
// Calculator
//
// Created by etudiant on 30/05/2023.
//
import Foundation
struct Maquette {
var listeBlocs: [Bloc]
var listeUEs: [UE]
public init( listeBlocs: [Bloc], listeUEs: [UE]) {
self.listeBlocs = listeBlocs
self.listeUEs = listeUEs
}
}

@ -0,0 +1,31 @@
//
// File.swift
// Calculator
//
// Created by etudiant on 23/05/2023.
//
import Foundation
struct Matieres: Identifiable, Equatable{
static func == (lhs: Matieres, rhs: Matieres) -> Bool {
lhs.id == rhs.id
}
let id : UUID
var name: String
var coef : Int
var note : Double
public init(name: String, coef: Int, note: Double) {
self.id = UUID()
self.name = name
self.coef = coef
self.note = note
}
public init(name: String,note: Double,coef:Int) {
self.id = UUID()
self.name = name
self.note = note
self.coef=coef
}
}

@ -0,0 +1,31 @@
//
// Bed.swift
// Calculator
//
// Created by etudiant on 23/05/2023.
//
import Foundation
public struct UE: Identifiable,Equatable {
public static func == (lhs: UE, rhs: UE) -> Bool {
lhs.id == rhs.id
}
public let id: UUID
var name: String
var coef : Int
var listMatiere: [Matieres]
var generalNote: Double{
return Double(listMatiere.reduce(0) { $0+$1.note }) / Double(listMatiere.count)
}
init(name: String,listMatiere: [Matieres],coef:Int) {
self.id = UUID()
self.name = name
self.listMatiere = listMatiere
self.coef=coef
}
}

@ -0,0 +1,6 @@
{
"info" : {
"author" : "xcode",
"version" : 1
}
}

@ -0,0 +1,35 @@
//
// AddMat.swift
// Calculator
//
// Created by etudiant on 21/06/2023.
//
import SwiftUI
struct AddMat: View {
@ObservedObject var mat : MatieresVM
var body: some View {
VStack{
HStack{
Text("Nom : ")
TextField("Name", text: $mat.name)
}
Divider()
HStack{
Text("Coef : ")
TextField("Coefficient", value: $mat.coef, format: .number)
}
}.frame(height: 250)
}
}
struct AddMat_Previews: PreviewProvider {
static var previews: some View {
AddMat(mat: MatieresVM())
}
}

@ -0,0 +1,35 @@
//
// BlocItem.swift
// Calculator
//
// Created by etudiant on 23/06/2023.
//
import SwiftUI
struct BlocItem: View {
@Binding var total : Double
@Binding var name : String
var body: some View {
HStack(spacing: 15) {
Grid{
GridRow {
Text(self.name)
Text( self.total,format: .number)
}
}
}
}
}
struct BlocItem_Previews: PreviewProvider {
static var previews: some View {
BlocItem(total: .constant( 15.5), name: .constant( "Total"))
}
}

@ -0,0 +1,94 @@
//
// BlocView.swift
// Calculator
//
// Created by etudiant on 20/06/2023.
//
import SwiftUI
struct BlocView: View {
@ObservedObject var manager : ManagerVM
var body: some View {
ScrollView{
ZStack{
VStack(alignment: .leading){
Text("Calculette")
.font(.largeTitle)
.fontWeight(.bold)
.padding(.leading, 12.0)
VStack(alignment: .leading){
HStack {
Image(systemName: "doc.on.doc.fill")
.foregroundColor(.accentColor)
Text("Block")
.font(.title)
}
VStack{
Text("Vous devez avoir la moyenne à chacun de ces blocs pour avoir votre diplome ")
.padding(.horizontal, 16.0)
}
HStack {
Image(systemName: "doc.on.doc.fill")
.foregroundColor(.accentColor)
Text("Total")
Spacer()
// BlocItem(total: .constant( manager.total), name: .constant(""))
Text(String(manager.total))
Image(systemName: "graduationcap.circle.fill")
}
HStack {
Image(systemName: "doc.on.doc.fill")
.foregroundColor(.accentColor)
Text("Projet/Stage")
Spacer()
ForEach(manager.blocs) { item in
if item.isUnique {
BlocItem(total: .constant(item.TotalNote), name: .constant(item.name))
Divider()
}
}
Image(systemName: "graduationcap.circle.fill")
}
}.padding()
.background(Color.clear)
.overlay(
RoundedRectangle(cornerRadius: 10)
.stroke(Color.gray, lineWidth: 1)
)
}}
}
}
}
struct BlocView_Previews: PreviewProvider {
static var previews: some View {
let bloc = [
BlocVM(withModel: Bloc(name: "Total", ListUE: StubUE().loadUEs(), isUq: false)),
BlocVM(withModel: Bloc(name: "", ListUE: StubUE().loadUeStage_Proj(), isUq: true))
]
BlocView(manager: ManagerVM(withBeds: bloc))
}
}

@ -0,0 +1,76 @@
import SwiftUI
struct EditMatView: View {
@ObservedObject var matiere : MatieresVM
var body: some View {
NavigationLink{
Form{
TextField("", text: $matiere.name, prompt: Text("enter the name"))
}
.navigationBarTitleDisplayMode(.inline)
.navigationTitle("Matiere")
}
label: {
HStack{
Text("Name")
Spacer()
Text(matiere.name)
.foregroundColor(.gray)
}
}
NavigationLink{
Form{
TextField("", value: $matiere.coef, format: .number, prompt: Text("enter the coef"))
}
.navigationBarTitleDisplayMode(.inline)
.navigationTitle("entez coef")
}
label: {
HStack{
Text("Coef")
Spacer()
Text(String(matiere.coef))
.foregroundColor(.gray)
}
}
NavigationLink{
Form{
TextField("", value: $matiere.note, format: .number, prompt: Text("enter the coef"))
}
.navigationBarTitleDisplayMode(.inline)
.navigationTitle("entez coef")
}
label: {
HStack{
Text("Note")
Spacer()
Text(String(matiere.note))
.foregroundColor(.gray)
}
}
}
}
struct EditMatView_Previews: PreviewProvider {
static var previews: some View {
let matiere = MatieresVM(withModel: StubMatiere().UE4().first!)
EditMatView(matiere: matiere)
}
}

@ -0,0 +1,177 @@
//
// ItemView.swift
// Calculator
//
// Created by etudiant on 23/05/2023.
//
import SwiftUI
struct EditView: View {
@ObservedObject var ue : UeVM
@ObservedObject var bloc : BlocVM
var body: some View {
NavigationView{
ScrollView{
VStack(alignment : .leading){
HStack {
Text(ue.name)
Spacer()
Text("\(ue.coef)")
Spacer()
}
.padding(.horizontal, 16.0)
HStack {
Capsule()
.fill(ue.generalNote < 10 ? .red : .blue)
.frame(height: 20)
.frame(width: CGFloat(ue.generalNote) * 10) // Utilisez la valeur de la note pour définir la largeur de la barre
.background(Color.clear)
Text("\(ue.generalNote)")
}.padding()
HStack{
Image(systemName: "x.circle.fill")
Text("Coefficient :")
Text("\(ue.coef)")
}
HStack{
Image(systemName: "note.text")
Text("Détails des notes")
}
Divider()
ForEach(ue.someMatiereVM) { mat in
MatiereView(mat: mat, ue: ue, bloc: bloc )
}
}
}
}
.navigationBarItems(
trailing:
HStack {
Button(action: {
self.ue.onEditing()
}) {
Text("Edit")
.foregroundColor(Color.blue)
}
}
)
.sheet(isPresented: $ue.isEditing){
NavigationStack{
Editpage(editUe: ue)
.toolbar{
ToolbarItem(id: "done", placement: .confirmationAction){
Button(action: {
// self.isEditing.toggle()
self.ue.onEdited(isCancelled: true)
print(self.ue.isEditing)
}){
Text("Done")
}
}
ToolbarItem(id: "cancel", placement: .cancellationAction){
Button(action: {
self.ue.onEdited()
}){
Text("Cancel")
}
}
ToolbarItem(id: "Add", placement: .cancellationAction){
Button(action: {
self.ue.onAdding()
print(ue.isAdding)
}) {
Text("Ajouter")
}
}
}
}
.navigationTitle("Edit: \(ue.name)")
}
.sheet(isPresented: $ue.isAdding){
NavigationStack{
AddMat(mat: self.ue.addedItem ?? MatieresVM())
.toolbar{
ToolbarItem(id: "done", placement: .confirmationAction){
Button(action: {
self.ue.onAdded()
}){
Text("Done")
}
}
ToolbarItem(id: "cancel", placement: .cancellationAction){
Button(action: {
self.ue.onAdded()
}){
Text("Cancel")
}
}
}
}
}
}
}
struct EditView_Previews: PreviewProvider {
static var previews: some View {
let ue = StubUE().loadUEs().last!
EditView(ue:UeVM(withModel:ue), bloc : BlocVM(withModel: Bloc(name: "Stage", ListUE: StubUE().loadUeStage_Proj(), isUq: true)))
}
}

@ -0,0 +1,100 @@
//
// Editpage.swift
// Calculator
//
// Created by etudiant on 20/06/2023.
//
import Foundation
import SwiftUI
struct Editpage: View {
@ObservedObject var editUe:UeVM
@State var isEditing: Bool = false
var body: some View {
NavigationStack{
VStack{
Form{
NavigationLink{
Form{
TextField("", text: $editUe.name, prompt: Text("enter the name"))
}
.navigationBarTitleDisplayMode(.inline)
.navigationTitle("Name")
}
label: {
HStack{
Text("Name")
Spacer()
Text(editUe.name)
.foregroundColor(.gray)
}
}
NavigationLink{
Form{
TextField("", value: $editUe.coef, format: .number, prompt: Text("enter the coef"))
}
.navigationBarTitleDisplayMode(.inline)
.navigationTitle("entez coef")
}
label: {
HStack{
Text("Entrez coef")
Spacer()
Text(String(editUe.coef))
.foregroundColor(.gray)
}
}
Label("Liste des matières", systemImage: "newspaper.fill").font(.title).padding()
ForEach(editUe.someMatiereVM ){ mat in
NavigationLink{
EditMatView(matiere : mat)
.navigationTitle("Matiere")
}
label: {
HStack{
Text(mat.name)
}
.swipeActions(edge:.trailing){
Button(role: .destructive) {
self.editUe.onDeleted(mat)
} label: {
Label("Delete", systemImage: "trash")
}
}
}
Spacer()
}
}
}
}
}
}
struct Editpage_Previews: PreviewProvider {
static var previews: some View {
let ue = StubUE().loadUEs().first!
Editpage(editUe:UeVM(withModel:ue))
}
}

@ -0,0 +1,74 @@
//
// BedView.swift
// Calculator
//
// Created by etudiant on 23/05/2023.
//
import SwiftUI
struct HomeView: View {
@StateObject var manager: ManagerVM
var body: some View {
NavigationView{
ScrollView{
ZStack{
VStack(alignment: .leading){
/*Text("Calculette")
.font(.largeTitle)
.fontWeight(.bold)
.padding(.leading, 12.0)*/
VStack(alignment: .leading){
BlocView(manager: manager)
VStack(alignment: .leading) {
HStack{
Text("Détail des UEs")
Spacer()
}
ForEach(manager.blocs) { item in
ForEach(item.someUeVM) {
ue in
UEview(bloc: item, ue: ue)
}
}
Divider()
}
.padding()
.background(Color.clear)
.overlay(
RoundedRectangle(cornerRadius: 10)
.stroke(Color.gray, lineWidth: 1)
)
}
}}
}
}
}
}
struct HomeView_Previews: PreviewProvider {
static var previews: some View {
let managerVM = ManagerVM(withBeds: [BlocVM(withModel: Bloc(name: "Total", ListUE: StubUE().loadUEs(), isUq: false)),BlocVM(withModel: Bloc(name: "Projet", ListUE: StubUE().loadUeStage_Proj(),isUq: true))])
HomeView(manager: managerVM )
}
}

@ -0,0 +1,95 @@
//
// MatiereView.swift
// Calculator
//
// Created by etudiant on 29/05/2023.
//
import SwiftUI
struct MatiereView: View {
@ObservedObject var mat: MatieresVM
@ObservedObject var ue : UeVM
@ObservedObject var bloc : BlocVM
@State private var isClicked : Bool = false;
@State var isEditing: Bool = false
var body: some View {
VStack(alignment : .leading){
HStack {
Text(mat.name)
.font(.title2)
Spacer()
Text("\(mat.coef)")
.font(.title2)
.padding(.horizontal, 30.0)
}
.padding(.horizontal, 11.0)
Button (action:{
isClicked.toggle()
self.mat.onEditing()
}){
Image(systemName: isClicked ? "lock.open": "lock")
.resizable()
.aspectRatio(contentMode: .fit)
.frame(width: 20, height: 20)
.foregroundColor(Color.blue)
.padding(.leading, 11.0)
}
HStack {
GeometryReader { geometry in
HStack {
Capsule()
.fill(mat.note < 10 ? .red : .green)
.frame(height: 20)
.frame(width: CGFloat(mat.note) / 30 * geometry.size.width)
.gesture(
isClicked ?
DragGesture(minimumDistance: 0)
.onChanged({ value in
let newNote = value.location.x / geometry.size.width * 20
mat.note = min(max(newNote, 0), 20)
})
:
DragGesture(minimumDistance: 0).onChanged({_ in })
)
Text("\(String(mat.note))")
if !isClicked{
Image("gouffle")
.resizable()
.frame(width: 20, height: 20)
}
}
}
.padding(.horizontal, 25.0)
}
Divider()
}
}
}
struct MatiereView_Previews: PreviewProvider {
static var previews: some View {
MatiereView(mat: MatieresVM(withModel: Matieres(name: "JAVA", coef: 6, note: 19)), ue: UeVM(withModel: StubUE().loadUeStage_Proj()[0]),bloc: BlocVM(withModel: Bloc(name: "", ListUE: StubUE().loadUeStage_Proj(), isUq: true)))
}
}

@ -0,0 +1,15 @@
import SwiftUI
struct Test: View {
var body: some View {
VStack {
Text("Je suis un TEST")
}
}
}
struct Test_Previews: PreviewProvider {
static var previews: some View {
Test()
}
}

@ -0,0 +1,57 @@
//
// UEview.swift
// Calculator
//
// Created by etudiant on 26/05/2023.
//
import SwiftUI
struct UEview: View {
@ObservedObject var bloc : BlocVM
@ObservedObject var ue: UeVM
var body: some View {
VStack(alignment : .leading){
HStack {
Text(ue.name)
Spacer()
Text("\(ue.coef)")
NavigationLink(destination: EditView(ue: ue, bloc: bloc) ){
Image(systemName: "square.and.pencil")
.foregroundColor(Color.blue)
}
}
.padding(.horizontal, 16.0)
HStack {
Capsule()
.fill(ue.generalNote < 10 ? .red : .blue)
.frame(height: 20)
.frame(width: CGFloat(ue.generalNote) * 10)
.background(Color.clear)
Text(String(ue.generalNote))
}.padding()
Divider()
}
}
}
struct UEview_Previews: PreviewProvider {
static var previews: some View {
let ue = StubUE().loadUEs().first!
let UeVM = UeVM(withModel: ue)
UEview(bloc: BlocVM(withModel: Bloc(name: "Projet/Stage", ListUE : StubUE().loadUeStage_Proj(),isUq: true)), ue: UeVM)
}
}

@ -0,0 +1,19 @@
//
// ArrayExtension.swift
// Calculator
//
// Created by etudiant on 14/06/2023.
//
import Foundation
extension Array where Element: Equatable {
func compare(to other: [Element]) -> Bool {
self.count == other.count && self.allSatisfy({ elt in
other.contains { otherElt in
otherElt == elt
}
})
}
}

@ -0,0 +1,168 @@
//
// BlocVM.swift
// Calculator
//
// Created by etudiant on 15/06/2023.
//
import Foundation
class BlocVM : ObservableObject,Identifiable,Equatable,Hashable{
public init(){}
static func == (lhs: BlocVM, rhs: BlocVM) -> Bool {
lhs.id == rhs.id
}
public var id: UUID { model.id }
func hash(into hasher: inout Hasher) {
hasher.combine(self.name)
hasher.combine(self.TotalNote)
}
init(withBloc blc : Bloc) {
self.model = blc
}
@Published var model: Bloc = Bloc(name: "Total", ListUE: StubUE().loadUEs(),isUq: false){
willSet(newValue) {
if !self.someUeVM.map({$0.model}).compare(to: newValue.listUE){
self.someUeVM.forEach { uevm in
uevm.unsubscribe(with: self)
}
}
}
didSet {
if self.model.name != self.name {
self.name = self.model.name
}
if self.model.isUnique != self.isUnique {
self.isUnique = self.model.isUnique
}
if !self.model.listUE.compare(to: self.someUeVM.map({$0.model})){
self.someUeVM = self.model.listUE.map({UeVM(withModel: $0)})
self.someUeVM.forEach{
uev in uev.subscribe(with: self, andWithFunction: onNotifyChanged(source:))
}
}
let not = updateTotalNote()
if not != self.TotalNote {
self.TotalNote = not
}
self.onNotifyChanged()
}
}
@Published var name: String = "" {
didSet {
if self.model.name != self.name {
self.model.name = self.name
}
}
}
@Published var someUeVM: [UeVM] = [] {
didSet {
let someModelUe = self.someUeVM.map({$0.model})
if !self.model.listUE.compare(to: someModelUe){
self.model.listUE = someUeVM.map({$0.model})
}
}
}
public init(withModel model: Bloc){
self.model = model
}
@Published var isEditing: Bool = false
private var copy: BlocVM { BlocVM(withModel: self.model) }
private var notificationFuncs: [AnyHashable:(BlocVM) -> ()] = [:]
var editedCopy: BlocVM?
func onEditing(){
editedCopy = self.copy
isEditing = true
}
func onEdited(isCancelled cancel: Bool = false) {
if !cancel {
if let editedCopy = editedCopy {
self.model = editedCopy.model
}
}
editedCopy = nil
isEditing = false
}
func onNotifyChanged(source:UeVM){
if let index = self.model.listUE.firstIndex(where: {$0 == source.model}) {
self.model.listUE[index] = source.model
}
self.objectWillChange.send()
}
@Published var TotalNote: Double = 0.0 {
didSet{
let not = updateTotalNote()
if not != self.TotalNote {
self.TotalNote = not
}
self.onNotifyChanged()
}
}
private func onNotifyChanged(){
for f in notificationFuncs.values {
print("notif")
f(self)
}
}
public func updateTotalNote()->Double {
let totalnote = self.someUeVM.reduce(0.0) { $0 + Double($1.generalNote) * Double($1.coef) }
let totalCoef = self.someUeVM.reduce(0.0) { $0 + Double($1.coef) }
print("bloc")
print( totalnote / totalCoef)
return totalnote / totalCoef
}
public func subscribe(with subscriber: AnyHashable, andWithFunction function:@escaping (BlocVM) -> ()) {
notificationFuncs[subscriber] = function
}
public func unsubscribe(with subscriber: AnyHashable) {
notificationFuncs.removeValue(forKey: subscriber)
}
@Published var isUnique : Bool = false {
didSet{
if self.isUnique != self.model.isUnique {
self.model.isUnique = self.isUnique
}
}
}
}
/* public let id: UUID
public var name: String
public var moyenneBloc: Double
public var listUE: [UE]*/
/*UE = list de matiere*/

@ -0,0 +1,66 @@
//
// ManagerVM.swift
// Calculator
//
// Created by etudiant on 20/06/2023.
//
import Foundation
class ManagerVM: ObservableObject,Hashable {
@Published var blocs: [BlocVM] = []
static func == (lhs: ManagerVM, rhs: ManagerVM) -> Bool {
lhs.blocs.compare(to: rhs.blocs)
}
func onNotifyChanged(source:BlocVM){
self.objectWillChange.send()
}
public init(withBeds blocs: [Bloc]){
self.blocs = blocs.map({BlocVM(withModel: $0)})
self.blocs.forEach { blocvm in
blocvm.subscribe(with: self, andWithFunction: onNotifyChanged(source:))
}
}
public init(withBeds blocs: [BlocVM]){
self.blocs = blocs
self.blocs.forEach { blocvm in
blocvm.subscribe(with: self, andWithFunction: onNotifyChanged(source:))
}
}
//var addedItem: BlocVM?
// @Published var isAdding: Bool = false
/* func onAdding() {
addedItem = BlocVM()
isAdding = true
}*/
var total : Double {
return Double(blocs.reduce(into: 0) { $0 + $1.TotalNote }) / Double(blocs.count)
}
/* func onAdded(isCancelled cancel:Bool = false) {
if !cancel {
if let addedItem = addedItem {
self.blocs.append(addedItem)
}
}
addedItem = nil
isAdding = false
}*/
func hash(into hasher: inout Hasher) {
hasher.combine("Manager")
}
}

@ -0,0 +1,113 @@
//
// MatieresVM.swift
// Calculator
//
// Created by etudiant on 09/06/2023.
//
import Foundation
class MatieresVM : ObservableObject, Identifiable, Equatable{
public init(){}
@Published
var isEditing: Bool = false
init(withMat mat : Matieres) {
self.model = mat
}
private var copy: MatieresVM { MatieresVM(withModel: self.model) }
var editedCopy: MatieresVM?
func onEditing(){
editedCopy = self.copy
isEditing = true
}
func onEdited(isCancelled cancel: Bool = false) {
if !cancel {
if let editedCopy = editedCopy {
self.model = editedCopy.model
}
}
editedCopy = nil
isEditing = false
}
private var notificationFuncs: [AnyHashable:(MatieresVM) -> ()] = [:]
public func subscribe(with subscriber: AnyHashable, andWithFunction function:@escaping (MatieresVM) -> ()) {
notificationFuncs[subscriber] = function
}
public func unsubscribe(with subscriber: AnyHashable) {
notificationFuncs.removeValue(forKey: subscriber)
}
static func == (lhs: MatieresVM, rhs: MatieresVM) -> Bool {
lhs.id == rhs.id
}
func notifyChanged(){
for f in notificationFuncs.values {
f(self)
}
}
public init(withModel model: Matieres){
self.model = model
}
public var id: UUID { model.id }
@Published var model: Matieres = Matieres(name: "", note: 0 , coef: 0){
didSet{
if self.model.name != self.name{
self.name = self.model.name
}
if self.model.coef != self.coef{
self.coef = self.model.coef
}
if self.model.note != self.note{
self.note = self.model.note
}
self.notifyChanged()
}
}
@Published var name : String = ""{
didSet{
if self.model.name != self.name {
self.model.name = self.name
}
}
}
@Published var coef : Int = 0{
didSet{
if self.model.coef != self.coef {
self.model.coef = self.coef
}
}
}
@Published var note : Double = 0{
didSet{
if self.model.note != self.note{
self.model.note = self.note
}
}
}
}
/*
public var name: String
public var coef : Int
public var note : Double
*/

@ -0,0 +1,11 @@
//
// ItemViewModel.swift
// Calculator
//
// Created by etudiant on 23/05/2023.
//
import Foundation
class UEViewModel: ObservableObject {
}

@ -0,0 +1,191 @@
//
// UeVM.swift
// Calculator
//
// Created by etudiant on 14/06/2023.
//
import Foundation
class UeVM : ObservableObject,Identifiable,Equatable,Hashable{
public init(){}
@Published
var isEditing: Bool = false
private var notificationFuncs: [AnyHashable:(UeVM) -> ()] = [:]
private var copy: UeVM { UeVM (withModel: self.model) }
public func subscribe(with subscriber: AnyHashable, andWithFunction function:@escaping (UeVM) -> ()) {
notificationFuncs[subscriber] = function
}
public func unsubscribe(with subscriber: AnyHashable) {
notificationFuncs.removeValue(forKey: subscriber)
}
var editedCopy: UeVM?
func hash(into hasher: inout Hasher) {
hasher.combine(self.name)
hasher.combine(self.generalNote)
}
func onEditing(){
editedCopy = self.copy
isEditing = true
isAdding = false
}
func onEdited(isCancelled cancel: Bool = false) {
if !cancel {
if let editedCopy = editedCopy {
self.model = editedCopy.model
}
}
editedCopy = nil
isEditing = false
}
var addedItem: MatieresVM? = MatieresVM(withModel: Matieres(name: "", note: 0.0, coef: 0)) /// ?
static func == (lhs: UeVM, rhs: UeVM) -> Bool {
lhs.id == rhs.id
}
@Published var model : UE = StubUE().loadUEs().first!{
willSet(newValue) {
if !self.someMatiereVM.map({$0.model}).compare(to: newValue.listMatiere){
self.someMatiereVM.forEach { $0.unsubscribe(with: self) }
}
}
didSet{
if self.model.name != self.name {
self.name = self.model.name
}
if self.model.coef != self.coef {
self.coef = self.model.coef
}
if !self.model.listMatiere.compare(to: self.someMatiereVM.map({$0.model})){
self.someMatiereVM = self.model.listMatiere.map({MatieresVM(withModel: $0)})
self.someMatiereVM.forEach { mvm in
mvm.subscribe(with: self, andWithFunction: onNotifyChanged(source:))
}
}
let note = updateTotalNote()
if note != self.generalNote {
self.generalNote = note
}
self.onNotifyChanged()
}
}
public var id: UUID { model.id }
@Published var name: String = "" {
didSet {
if self.model.name != self.name {
self.model.name = self.name
}
}
}
@Published var coef: Int = 0 {
didSet {
if self.model.coef != self.coef {
self.model.coef = self.coef
}
}
}
@Published
var generalNote : Double = 0.0 {
didSet {
let note = updateTotalNote()
if note != self.generalNote {
self.generalNote = note
}
}
}
public func updateTotalNote()->Double {
let totalNote = someMatiereVM.reduce(0.0) { $0 + Double($1.note) * Double($1.coef) }
let totalCoef = someMatiereVM.reduce(0.0) { $0 + Double($1.coef) }
print("ue")
print(self.someMatiereVM.count)
return totalNote/totalCoef
}
@Published var someMatiereVM: [MatieresVM] = [] {
didSet {
let someModelMatiere = self.someMatiereVM.map({$0.model})
if !self.model.listMatiere.compare(to: someModelMatiere){
self.model.listMatiere = someMatiereVM.map({$0.model})
}
}
}
public init(withModel model: UE){
self.model = model
}
// var addedItem: MatieresVM?
@Published
var isAdding: Bool = false
func onAdding() {
addedItem = MatieresVM()
isEditing = false
isAdding = true
}
func onAdded(isCancelled cancel:Bool = false) {
if !cancel {
if let addedItem = addedItem {
self.someMatiereVM.append(addedItem)
}
}
addedItem = nil
isAdding = false
}
func onDeleted(_ matieres:MatieresVM, isCancelled cancel: Bool = false) {
if !cancel {
if self.someMatiereVM.contains(matieres) {
self.someMatiereVM.removeAll(where: {$0 == matieres})
}
}
}
func onNotifyChanged(){
for f in notificationFuncs.values {
f(self)
}
}
func onNotifyChanged(source:MatieresVM){
if let index = self.model.listMatiere.firstIndex(where: {$0 == source.model}) {
self.model.listMatiere[index] = source.model
}
self.objectWillChange.send()
}
}
/*public let id: UUID
public var name: String
public var coef : Int
public var listMatiere: [Matieres]
public var generalNote: Double {*/

@ -0,0 +1,36 @@
//
// CalculatorTests.swift
// CalculatorTests
//
// Created by etudiant on 23/05/2023.
//
import XCTest
@testable import Calculator
final class CalculatorTests: XCTestCase {
override func setUpWithError() throws {
// Put setup code here. This method is called before the invocation of each test method in the class.
}
override func tearDownWithError() throws {
// Put teardown code here. This method is called after the invocation of each test method in the class.
}
func testExample() throws {
// This is an example of a functional test case.
// Use XCTAssert and related functions to verify your tests produce the correct results.
// Any test you write for XCTest can be annotated as throws and async.
// Mark your test throws to produce an unexpected failure when your test encounters an uncaught error.
// Mark your test async to allow awaiting for asynchronous code to complete. Check the results with assertions afterwards.
}
func testPerformanceExample() throws {
// This is an example of a performance test case.
self.measure {
// Put the code you want to measure the time of here.
}
}
}

@ -0,0 +1,41 @@
//
// CalculatorUITests.swift
// CalculatorUITests
//
// Created by etudiant on 23/05/2023.
//
import XCTest
final class CalculatorUITests: XCTestCase {
override func setUpWithError() throws {
// Put setup code here. This method is called before the invocation of each test method in the class.
// In UI tests it is usually best to stop immediately when a failure occurs.
continueAfterFailure = false
// In UI tests its important to set the initial state - such as interface orientation - required for your tests before they run. The setUp method is a good place to do this.
}
override func tearDownWithError() throws {
// Put teardown code here. This method is called after the invocation of each test method in the class.
}
func testExample() throws {
// UI tests must launch the application that they test.
let app = XCUIApplication()
app.launch()
// Use XCTAssert and related functions to verify your tests produce the correct results.
}
func testLaunchPerformance() throws {
if #available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 7.0, *) {
// This measures how long it takes to launch your application.
measure(metrics: [XCTApplicationLaunchMetric()]) {
XCUIApplication().launch()
}
}
}
}

@ -0,0 +1,32 @@
//
// CalculatorUITestsLaunchTests.swift
// CalculatorUITests
//
// Created by etudiant on 23/05/2023.
//
import XCTest
final class CalculatorUITestsLaunchTests: XCTestCase {
override class var runsForEachTargetApplicationUIConfiguration: Bool {
true
}
override func setUpWithError() throws {
continueAfterFailure = false
}
func testLaunch() throws {
let app = XCUIApplication()
app.launch()
// Insert steps here to perform after app launch but before taking a screenshot,
// such as logging into a test account or navigating somewhere in the app
let attachment = XCTAttachment(screenshot: app.screenshot())
attachment.name = "Launch Screen"
attachment.lifetime = .keepAlways
add(attachment)
}
}

Binary file not shown.

Binary file not shown.

After

Width:  |  Height:  |  Size: 246 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 227 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 168 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 310 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 210 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 210 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 318 KiB

Loading…
Cancel
Save