title: What is the difference between using <<access>> and <<import>> when implementing a package diagram?
body: <p>We are covering UML diagrams in one of my university modules, and we briefly covered package diagrams. I understand that in a package diagram, when there is a connection (or arrow) between two packages and it is labelled with import, it means that the contents of the target package are added to the source's public namespace, while access adds it to the private namespace and cannot be re-exported when a third package imports the original source package. My question is how would you actually implement the import and access in code? For example with Java you have;</p>
  
  <p>import Java.swing.*;</p>
  
  <p>As far as I know there is no access key-word, right? </p>
  
  <p>Thanks</p>