mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-07-24 01:15:29 +02:00
IsReadonly new method
This commit is contained in:
parent
ba7d1abca2
commit
f3f0b3d63c
1 changed files with 14 additions and 0 deletions
|
@ -94,6 +94,20 @@ class CElementInfo {
|
|||
return fIsStructureKnown;
|
||||
}
|
||||
|
||||
/**
|
||||
* @see ICElement.isStructureKnown()
|
||||
*/
|
||||
public boolean isReadOnly () {
|
||||
try {
|
||||
IResource r = getElement().getUnderlyingResource();
|
||||
if (r != null) {
|
||||
return r.isReadOnly();
|
||||
}
|
||||
} catch (CModelException e) {
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns an array with all the same elements as the specified array except for
|
||||
* the element to remove. Assumes that the deletion is contained in the array.
|
||||
|
|
Loading…
Add table
Reference in a new issue