On Sun, Dec 30, 2018, 5:02 PM <cinemat...@gmail.com> wrote:

> I'm a beginner in Golang and quite confusing about using packages in a
> program. For example, every non simple software has a bunch of classes and
> interfaces or utility classes which are usually lokated in different
> packages in the same program. So using them in Java fo example makes no
> diffculty at all, but it seems Golang makes this diffculty then it comes
> for using packages.
>

Can you clarify what you mean by "difficulty" here? The following examples
of accessing imported packages by their namespace doesn't seem to qualify
as difficult so maybe some details of your experience have been left out?
If the package namespace are what you meant as bering undesirable, would
you prefer a situation like C where you include a dependency and a Foo
struct is accessible in the global namespace as Foo? What happens then if
two dependencies provide Foo structs?

When classes(structures, methods) are placed in different packages we
> should import them and then using them with the package name like
> "utility.MyStructure" or "model.DemoStruct" - is not it an overhead using
> every time package names when referencing structures of methods from
> different packages of the same program?
>
> --
> You received this message because you are subscribed to the Google Groups
> "golang-nuts" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to golang-nuts+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to