Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
Copyright (c) 2009 itemis AG (http://www.itemis.eu) and others. All rights reserved. This program and the accompanying materials are made available under the terms of the Eclipse Public License v1.0 which accompanies this distribution, and is available at http://www.eclipse.org/legal/epl-v10.html /
  
  package org.eclipse.xtext.ui.editor;
  
Representation of a resource that is currently edited. The accessible values may represent a cached, intermediate state of the resource. They are not necessarily a live view on the underlying resource.

Author(s):
Sebastian Zarnekow - Initial contribution and API
 
 public interface IDirtyResource {

Returns:
the content of the resource as text, never null. May be the content of a snapshot.
See also:
IDirtyResource.InitializationAware.getContentsIfInitialized()
 

Returns:
the current content of the underlying document or resource as text, never null.
See also:
IDirtyResource.InitializationAware.getActualContentsIfInitialized()
 

Returns:
the description of the resource, never null.
See also:
IDirtyResource.InitializationAware.getDescriptionIfInitialized()
 

Returns:
the URI of the resource, never null.
 
 	URI getURI();

An extension interface for IDirtyResource

Since:
2.4
 

Returns:
the normalized URI of the resource, never null.
 
 	}

An extension interface for IDirtyResource. Still provisional

Since:
2.8
Noreference:
This interface is not intended to be referenced by clients.
Noextend:
This interface is not intended to be extended by clients.
Noimplement:
This interface is not intended to be implemented by clients.
 

Noreference:
This method is not intended to be referenced by clients.
Nooverride:
This default method is not intended to be re-implemented or extended by clients.
 
 	}

Allows to query the dirty resource for its initialization state.

Author(s):
Sebastian Zarnekow - Initial contribution and API
Since:
2.8
Noextend:
This interface is not intended to be extended by clients.
Noimplement:
This interface is not intended to be implemented by clients.
Noreference:
This method is not intended to be referenced by clients.
 
 	interface InitializationAware extends IDirtyResource{

Returns true if the resource is initialized.
 
 		boolean isInitialized();

Returns the content of the resource as text. If the dirty description is not yet initialized, returns null.

 
Returns the current content of the underlying document or resource as text. If the dirty description is not yet initialized, returns null.

Returns:
the description of the resource or null, if the resource is not yet initialized.
See also:
IDirtyResource.getDescription()
	}
New to GrepCode? Check out our FAQ X