lascarayf
lascarayf

Reputation: 3743

Dart library / package keyword meaning?

Is Dart library exactly the same Java package ?

Is Dart package exactly the same Java library (JAR) ?

Upvotes: 7

Views: 1704

Answers (1)

Günter Zöchbauer
Günter Zöchbauer

Reputation: 657929

A package is a set of libraries which can for example be deployed to pub.dartlang.org. I guess this is similar to a jar file.
A library is one Dart script file with or without a name (or a set of Dart script files with part/part of) and is the boundary for privacy. Private members are only visible or accessible from within the same library.

Upvotes: 7

Related Questions