From: Marko Luukkainen Date: Wed, 25 Jan 2023 09:58:11 +0000 (+0000) Subject: Merge "Re-export Simantics/DB/findFreshName from Rename" into release/1.43.1 X-Git-Url: https://gerrit.simantics.org/r/gitweb?a=commitdiff_plain;h=refs%2Fheads%2Frelease%2F1.43.1;hp=b08fe9b9f595952b44db800abd7682232342c15f;p=simantics%2Fplatform.git Merge "Re-export Simantics/DB/findFreshName from Rename" into release/1.43.1 --- diff --git a/bundles/org.simantics.modeling/scl/Simantics/Rename.scl b/bundles/org.simantics.modeling/scl/Simantics/Rename.scl index e7667ed87..a597368f1 100644 --- a/bundles/org.simantics.modeling/scl/Simantics/Rename.scl +++ b/bundles/org.simantics.modeling/scl/Simantics/Rename.scl @@ -1,4 +1,5 @@ import "Simantics/Entity" hiding (findFreshName) +include "Simantics/DB" (findFreshName) importJava "org.simantics.modeling.Rename" where @JavaName renameNode @@ -35,18 +36,6 @@ renameMBNode :: Resource -> String -> String renameMBNode entity newname = renameNode entity newname importJava "org.simantics.db.common.utils.NameUtils" where - @JavaName findFreshName - """ - findFreshName name container - - Finds fresh and unused name with proposition `name` under the given `container` - and returns the freshName - - Example: - - freshName = findFreshName "Model" currentProject () - """ - findFreshName :: String -> Resource -> String @JavaName getSafeName """