diff --git a/build.sbt b/build.sbt index e7f8f14..4ce7137 100644 --- a/build.sbt +++ b/build.sbt @@ -58,4 +58,4 @@ lazy val scuid = ) ) -lazy val root = tlCrossRootProject.aggregate(core, scuid) +lazy val root = tlCrossRootProject.aggregate(core, scuid, uuid) diff --git a/uuid/src/main/scala/me/wojnowski/humanoid/uuid/HumanUuidOps.scala b/uuid/src/main/scala/me/wojnowski/humanoid/uuid/HumanUuidOps.scala index fd873f6..ea85d12 100644 --- a/uuid/src/main/scala/me/wojnowski/humanoid/uuid/HumanUuidOps.scala +++ b/uuid/src/main/scala/me/wojnowski/humanoid/uuid/HumanUuidOps.scala @@ -1,3 +1,24 @@ +/* + * Copyright (c) 2023 Jakub Wojnowski + * + * Permission is hereby granted, free of charge, to any person obtaining a copy of + * this software and associated documentation files (the "Software"), to deal in + * the Software without restriction, including without limitation the rights to + * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of + * the Software, and to permit persons to whom the Software is furnished to do so, + * subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS + * FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR + * COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER + * IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN + * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + */ + package me.wojnowski.humanoid.uuid import me.wojnowski.humanoid.HumanIdOps diff --git a/uuid/src/main/scala/me/wojnowski/humanoid/uuid/UuidIdConverter.scala b/uuid/src/main/scala/me/wojnowski/humanoid/uuid/UuidIdConverter.scala index 8a57206..056f871 100644 --- a/uuid/src/main/scala/me/wojnowski/humanoid/uuid/UuidIdConverter.scala +++ b/uuid/src/main/scala/me/wojnowski/humanoid/uuid/UuidIdConverter.scala @@ -1,3 +1,24 @@ +/* + * Copyright (c) 2023 Jakub Wojnowski + * + * Permission is hereby granted, free of charge, to any person obtaining a copy of + * this software and associated documentation files (the "Software"), to deal in + * the Software without restriction, including without limitation the rights to + * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of + * the Software, and to permit persons to whom the Software is furnished to do so, + * subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS + * FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR + * COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER + * IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN + * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + */ + package me.wojnowski.humanoid.uuid import me.wojnowski.humanoid.IdConverter diff --git a/uuid/src/main/scala/me/wojnowski/humanoid/uuid/UuidIdGenerator.scala b/uuid/src/main/scala/me/wojnowski/humanoid/uuid/UuidIdGenerator.scala index 0595572..1e9a172 100644 --- a/uuid/src/main/scala/me/wojnowski/humanoid/uuid/UuidIdGenerator.scala +++ b/uuid/src/main/scala/me/wojnowski/humanoid/uuid/UuidIdGenerator.scala @@ -1,7 +1,28 @@ +/* + * Copyright (c) 2023 Jakub Wojnowski + * + * Permission is hereby granted, free of charge, to any person obtaining a copy of + * this software and associated documentation files (the "Software"), to deal in + * the Software without restriction, including without limitation the rights to + * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of + * the Software, and to permit persons to whom the Software is furnished to do so, + * subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS + * FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR + * COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER + * IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN + * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + */ + package me.wojnowski.humanoid.uuid -import me.wojnowski.humanoid.IdGenerator import cats.effect.std.UUIDGen +import me.wojnowski.humanoid.IdGenerator import java.util.UUID diff --git a/uuid/src/main/scala/me/wojnowski/humanoid/uuid/package.scala b/uuid/src/main/scala/me/wojnowski/humanoid/uuid/package.scala index cf0162e..027dd15 100644 --- a/uuid/src/main/scala/me/wojnowski/humanoid/uuid/package.scala +++ b/uuid/src/main/scala/me/wojnowski/humanoid/uuid/package.scala @@ -1,3 +1,24 @@ +/* + * Copyright (c) 2023 Jakub Wojnowski + * + * Permission is hereby granted, free of charge, to any person obtaining a copy of + * this software and associated documentation files (the "Software"), to deal in + * the Software without restriction, including without limitation the rights to + * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of + * the Software, and to permit persons to whom the Software is furnished to do so, + * subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS + * FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR + * COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER + * IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN + * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + */ + package me.wojnowski.humanoid import java.util.UUID diff --git a/uuid/src/test/scala/UuidGeneratorTest.scala b/uuid/src/test/scala/UuidGeneratorTest.scala index a6893d9..41587f8 100644 --- a/uuid/src/test/scala/UuidGeneratorTest.scala +++ b/uuid/src/test/scala/UuidGeneratorTest.scala @@ -1,3 +1,24 @@ +/* + * Copyright (c) 2023 Jakub Wojnowski + * + * Permission is hereby granted, free of charge, to any person obtaining a copy of + * this software and associated documentation files (the "Software"), to deal in + * the Software without restriction, including without limitation the rights to + * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of + * the Software, and to permit persons to whom the Software is furnished to do so, + * subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS + * FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR + * COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER + * IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN + * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + */ + import cats.effect.std.UUIDGen import me.wojnowski.humanoid.HumanId import me.wojnowski.humanoid.HumanIdOps @@ -14,7 +35,7 @@ class UuidGeneratorTest extends FunSuite { val uuid1 = UUID.fromString("076831d6-41a0-4161-9217-fc04ac8fa5a2") - implicit val constTryUuidGen = new UUIDGen[Try] { + implicit val constTryUuidGen: UUIDGen[Try] = new UUIDGen[Try] { override def randomUUID: Try[UUID] = Success(uuid1) } diff --git a/uuid/src/test/scala/UuidIdConverterTest.scala b/uuid/src/test/scala/UuidIdConverterTest.scala index ecf2d36..4f2e2e1 100644 --- a/uuid/src/test/scala/UuidIdConverterTest.scala +++ b/uuid/src/test/scala/UuidIdConverterTest.scala @@ -1,3 +1,24 @@ +/* + * Copyright (c) 2023 Jakub Wojnowski + * + * Permission is hereby granted, free of charge, to any person obtaining a copy of + * this software and associated documentation files (the "Software"), to deal in + * the Software without restriction, including without limitation the rights to + * use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of + * the Software, and to permit persons to whom the Software is furnished to do so, + * subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS + * FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR + * COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER + * IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN + * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + */ + import me.wojnowski.humanoid.HumanId import me.wojnowski.humanoid.HumanIdOps import munit.FunSuite