java.lang.Object
java.lang.Record
org.aya.resolve.context.ModuleExport
public record ModuleExport(@NotNull ModuleSymbol<DefVar<?,?>> symbols, @NotNull kala.collection.mutable.MutableMap<ModuleName.Qualified,ModuleExport> modules)
extends Record
A data class that contains all public definitions/re-exports of some module.
-
Constructor Summary
ConstructorsConstructorDescriptionModuleExport(@NotNull ModuleExport that) ModuleExport(@NotNull ModuleSymbol<DefVar<?, ?>> symbols, @NotNull kala.collection.mutable.MutableMap<ModuleName.Qualified, ModuleExport> modules) Creates an instance of aModuleExportrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.booleanexport(@NotNull ModuleName modName, @NotNull String name, @NotNull DefVar<?, ?> ref) booleanexport(ModuleName.Qualified componentName, @NotNull ModuleExport module) final inthashCode()Returns a hash code value for this object.@NotNull kala.collection.mutable.MutableMap<ModuleName.Qualified,ModuleExport> modules()Returns the value of themodulesrecord component.@NotNull ModuleSymbol<DefVar<?,?>> symbols()Returns the value of thesymbolsrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
ModuleExport
public ModuleExport() -
ModuleExport
-
ModuleExport
public ModuleExport(@NotNull @NotNull ModuleSymbol<DefVar<?, ?>> symbols, @NotNull @NotNull kala.collection.mutable.MutableMap<ModuleName.Qualified, ModuleExport> modules) Creates an instance of aModuleExportrecord class.- Parameters:
symbols- the value for thesymbolsrecord componentmodules- the value for themodulesrecord component
-
-
Method Details
-
export
public boolean export(@NotNull @NotNull ModuleName modName, @NotNull @NotNull String name, @NotNull @NotNull DefVar<?, ?> ref) - Returns:
- false if there already exist a symbol with the same name.
-
export
public boolean export(@NotNull ModuleName.Qualified componentName, @NotNull @NotNull ModuleExport module) -
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
symbols
Returns the value of thesymbolsrecord component.- Returns:
- the value of the
symbolsrecord component
-
modules
@NotNull public @NotNull kala.collection.mutable.MutableMap<ModuleName.Qualified,ModuleExport> modules()Returns the value of themodulesrecord component.- Returns:
- the value of the
modulesrecord component
-