Follow-up to the moves in #938–#941; requires an API decision, so filed separately.
io.spine.code.fs (AbstractFileName, AbstractSourceFile, FsObject) and io.spine.code.proto.SourceFile are imported only by tooling (ToolBase; SourceFile also by the dormant mc-js), yet they cannot move today:
FileSet.topLevelMessages() and FileSet.findMessageTypes(Predicate) construct SourceFile, and FileSet is runtime-essential — KnownTypes.load() → FileSet.load() runs at application startup.
io.spine.code.proto.FileName (runtime: used by MessageFile, Type, FileSet) extends code.fs.AbstractFileName.
If the two FileSet methods are relocated to ToolBase (e.g. as extension functions over FileSet), SourceFile, AbstractSourceFile, and FsObject could follow to ToolBase. AbstractFileName stays in base regardless, because of FileName.
This changes the public API of a runtime type (FileSet), so it needs a design decision rather than a mechanical move. Pre-2.0 is the cheapest time if we want it at all.
Follow-up to the moves in #938–#941; requires an API decision, so filed separately.
io.spine.code.fs(AbstractFileName,AbstractSourceFile,FsObject) andio.spine.code.proto.SourceFileare imported only by tooling (ToolBase;SourceFilealso by the dormantmc-js), yet they cannot move today:FileSet.topLevelMessages()andFileSet.findMessageTypes(Predicate)constructSourceFile, andFileSetis runtime-essential —KnownTypes.load()→FileSet.load()runs at application startup.io.spine.code.proto.FileName(runtime: used byMessageFile,Type,FileSet) extendscode.fs.AbstractFileName.If the two
FileSetmethods are relocated to ToolBase (e.g. as extension functions overFileSet),SourceFile,AbstractSourceFile, andFsObjectcould follow to ToolBase.AbstractFileNamestays inbaseregardless, because ofFileName.This changes the public API of a runtime type (
FileSet), so it needs a design decision rather than a mechanical move. Pre-2.0 is the cheapest time if we want it at all.