Java中的软件包及其子软件包之间是什么关系? [英] What is the relationship between a package and its subpackage in Java?

查看:65
本文介绍了Java中的软件包及其子软件包之间是什么关系?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

可能重复:
Java:子包可见性?

这是问题 Java:子包可见性?的延续.提出这个问题的原因是为了引起广大社区的关注.

问题这两个软件包之间有任何关系:odp.proj和odp.proj.subpackage?

有人试图在此处回答它,但未能对其进行描述.

解决方案

不,Java语言的 odp.proj odp.proj.subpackage 之间没有关系看法.

对于代码,odp.proj.subpackage将驻留在odp.proj的子目录中,某些工具和IDE可能会将它们组合在一个UI中,但是关于语言访问控制或其他语言功能则没有关系./p>

Java没有子包的概念,因此odp.proj.subpackage和odp.proj与其他任何不同命名的包一样有区别.

Possible Duplicate:
Java: Subpackage visiblity?

This is a continuation of question Java: Subpackage visiblity?. The reason for asking is to draw attention of broader community.

Question Is there any relation between two packages: odp.proj and odp.proj.subpackage?

Someone tried to answer it here but failed to describe it.

解决方案

No, there's no relation between odp.proj and odp.proj.subpackage from the Java language perspective.

For code, odp.proj.subpackage would reside in a sub directory of odp.proj, and some tools and IDE's might group them together in a UI, but regarding language access control, or other langage feature there's no relation.

Java does not have the concept of a subpackage, so odp.proj.subpackage and odp.proj are as different from each other as any other differently named packages.

这篇关于Java中的软件包及其子软件包之间是什么关系?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆