Allows you to create an alias for a capsule that you import.
capsule-imports {
import (viv.core) {
as (core)
}
import (viv.self) {
as (self)
version (4.0.25)
}
import (viv.time) {
as (time)
version-from (self)
}
import (viv.money) {
as (money)
version (2.22.56)
}
}
capsule-imports {
import (viv.core) {
as (core)
}
import (viv.time) {
as (time)
version (3.3.34)
}
}
...
capsule-imports {
import (example.flight) {
as (flight)
version (1.0.2)
}
...
Aliases defined with as
can only be used in the capsule that declares them, not in capsules that import them. That is, in the example above, if example.flight
imports any capsules and declares aliases for them with as
, you cannot use the aliases defined in example.flight
in your capsule. If you need to do this, explicitly import the capsule using version-from
to remain in sync with the higher-level capsule:
...
capsule-imports {
import (example.flight) {
as (flight)
version (1.0.2)
}
import (example.foobar) {
as (foobar)
version-from (flight)
}
}
...
Copyright 2024 Samsung All rights reserved