Function: semantic-tag-package-protected-p
semantic-tag-package-protected-p is a byte-compiled function defined
in tag-ls.el.gz.
Signature
(semantic-tag-package-protected-p TAG &optional PARENT CURRENTPACKAGE)
Documentation
Non-nil if TAG is not available via package access control.
For languages (such as Java) where a method is package protected,
this method will return nil if TAG, as found in PARENT is available
for access from a file in CURRENTPACKAGE.
If TAG is not protected by PACKAGE, also return t. Use
semantic-tag-protected-p instead.
If PARENT is not provided, it will be derived when passed to
semantic-tag-protection.
If CURRENTPACKAGE is not provided, it will be derived from the current
buffer.
Source Code
;; Defined in /usr/src/emacs/lisp/cedet/semantic/tag-ls.el.gz
(defun semantic-tag-package-protected-p (tag &optional parent currentpackage)
"Non-nil if TAG is not available via package access control.
For languages (such as Java) where a method is package protected,
this method will return nil if TAG, as found in PARENT is available
for access from a file in CURRENTPACKAGE.
If TAG is not protected by PACKAGE, also return t. Use
`semantic-tag-protected-p' instead.
If PARENT is not provided, it will be derived when passed to
`semantic-tag-protection'.
If CURRENTPACKAGE is not provided, it will be derived from the current
buffer."
(let ((tagpro (semantic-tag-protection tag parent)))
(if (not (eq tagpro 'package))
t ;; protected
;; package protection, so check currentpackage.
;; Deriving the package is better from the parent, as TAG is
;; probably a field or method.
(if (not currentpackage)
(setq currentpackage (semantic-tag-full-package nil (current-buffer))))
(let ((tagpack (semantic-tag-full-package (or parent tag))))
(if (string= currentpackage tagpack)
nil
t)) )))