org.jomc.tools
Class JavaSources.JavaImplementationEditor

Package class diagram package JavaSources.JavaImplementationEditor
java.lang.Object
  extended by org.jomc.util.LineEditor
      extended by org.jomc.util.SectionEditor
          extended by org.jomc.tools.JavaSources.JavaEditor
              extended by org.jomc.tools.JavaSources.JavaImplementationEditor
Enclosing class:
JavaSources

public class JavaSources.JavaImplementationEditor
extends JavaSources.JavaEditor

Extension to JavaEditor for editing implementation source code.

Version:
$Id: JavaSources.java 891 2009-11-02 03:40:00Z schulte2005 $
Author:
Christian Schulte

Constructor Summary
JavaSources.JavaImplementationEditor(org.jomc.model.Implementation implementation)
          Creates a new JavaImplementationEditor instance for editing the source code of a given implementation.
JavaSources.JavaImplementationEditor(org.jomc.util.LineEditor lineEditor, org.jomc.model.Implementation implementation)
          Creates a new JavaImplementationEditor instance for editing the source code of a given implementation taking a LineEditor to chain.
 
Method Summary
 void editAnnotationsSection(org.jomc.util.Section s)
          Edits the annotations section of the source code of the editor.
 void editConstructorsSection(org.jomc.util.Section s)
          Edits the constructors section of the source code of the editor.
 void editDefaultConstructorSection(org.jomc.util.Section s)
          Edits the default constructor section of the source code of the editor.
 void editDependenciesSection(org.jomc.util.Section s)
          Edits the dependencies section of the source code of the editor.
 void editDocumentationSection(org.jomc.util.Section s)
          Edits the documentation section of the source code of the editor.
 void editLicenseSection(org.jomc.util.Section s)
          Edits the license section of the source code of the editor.
 void editMessagesSection(org.jomc.util.Section s)
          Edits the messages section of the source code of the editor.
 void editPropertiesSection(org.jomc.util.Section s)
          Edits the properties section of the source code of the editor.
 void editSection(org.jomc.util.Section section)
           
 String getOutput(org.jomc.util.Section section)
           
 boolean isConstructorsSectionPresent()
          Gets a flag indicating that the source code of the editor contains a constructors section.
 boolean isDefaultConstructorSectionPresent()
          Gets a flag indicating that the source code of the editor contains a default constructor section.
 boolean isDependenciesSectionPresent()
          Gets a flag indicating that the source code of the editor contains a dependencies section.
 boolean isMessagesSectionPresent()
          Gets a flag indicating that the source code of the editor contains a messages section.
 boolean isPropertiesSectionPresent()
          Gets a flag indicating that the source code of the editor contains a properties section.
 
Methods inherited from class org.jomc.tools.JavaSources.JavaEditor
isAnnotationsSectionPresent, isDocumentationSectionPresent, isLicenseSectionPresent
 
Methods inherited from class org.jomc.util.SectionEditor
editLine, getSection, isSectionFinished
 
Methods inherited from class org.jomc.util.LineEditor
edit, getLineSeparator
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JavaSources.JavaImplementationEditor

public JavaSources.JavaImplementationEditor(org.jomc.model.Implementation implementation)
Creates a new JavaImplementationEditor instance for editing the source code of a given implementation.

Parameters:
implementation - The implementation to edit.

JavaSources.JavaImplementationEditor

public JavaSources.JavaImplementationEditor(org.jomc.util.LineEditor lineEditor,
                                            org.jomc.model.Implementation implementation)
Creates a new JavaImplementationEditor instance for editing the source code of a given implementation taking a LineEditor to chain.

Parameters:
lineEditor - The editor to chain.
implementation - The implementation to edit.
Method Detail

getOutput

public String getOutput(org.jomc.util.Section section)
                 throws IOException
Overrides:
getOutput in class JavaSources.JavaEditor
Throws:
IOException

editSection

public void editSection(org.jomc.util.Section section)
                 throws IOException
Overrides:
editSection in class JavaSources.JavaEditor
Throws:
IOException

editLicenseSection

public void editLicenseSection(org.jomc.util.Section s)
                        throws IOException
Edits the license section of the source code of the editor.

Specified by:
editLicenseSection in class JavaSources.JavaEditor
Parameters:
s - The section to edit.
Throws:
IOException - if editing s fails.

editAnnotationsSection

public void editAnnotationsSection(org.jomc.util.Section s)
                            throws IOException
Edits the annotations section of the source code of the editor.

Specified by:
editAnnotationsSection in class JavaSources.JavaEditor
Parameters:
s - The section to edit.
Throws:
NullPointerException - if s is null.
IOException - if editing s fails.

editDocumentationSection

public void editDocumentationSection(org.jomc.util.Section s)
                              throws IOException
Edits the documentation section of the source code of the editor.

Specified by:
editDocumentationSection in class JavaSources.JavaEditor
Parameters:
s - The section to edit.
Throws:
NullPointerException - if s is null.
IOException - if editing s fails.

editConstructorsSection

public void editConstructorsSection(org.jomc.util.Section s)
                             throws IOException
Edits the constructors section of the source code of the editor.

Parameters:
s - The section to edit.
Throws:
NullPointerException - if s is null.
IOException - if editing s fails.

editDefaultConstructorSection

public void editDefaultConstructorSection(org.jomc.util.Section s)
                                   throws IOException
Edits the default constructor section of the source code of the editor.

Parameters:
s - The section to edit.
Throws:
NullPointerException - if s is null.
IOException - if editing s fails.

editDependenciesSection

public void editDependenciesSection(org.jomc.util.Section s)
                             throws IOException
Edits the dependencies section of the source code of the editor.

Parameters:
s - The section to edit.
Throws:
NullPointerException - if s is null.
IOException - if editing s fails.

editMessagesSection

public void editMessagesSection(org.jomc.util.Section s)
                         throws IOException
Edits the messages section of the source code of the editor.

Parameters:
s - The section to edit.
Throws:
NullPointerException - if s is null.
IOException - if editing s fails.

editPropertiesSection

public void editPropertiesSection(org.jomc.util.Section s)
                           throws IOException
Edits the properties section of the source code of the editor.

Parameters:
s - The section to edit.
Throws:
NullPointerException - if s is null.
IOException - if editing s fails.

isConstructorsSectionPresent

public boolean isConstructorsSectionPresent()
Gets a flag indicating that the source code of the editor contains a constructors section.

Returns:
true if the source code of the editor contains a constructors section; false if the source code of the editor does not contain a constructors section.

isDefaultConstructorSectionPresent

public boolean isDefaultConstructorSectionPresent()
Gets a flag indicating that the source code of the editor contains a default constructor section.

Returns:
true if the source code of the editor contains a default constructor section; false if the source code of the editor does not contain a default constructor section.

isMessagesSectionPresent

public boolean isMessagesSectionPresent()
Gets a flag indicating that the source code of the editor contains a messages section.

Returns:
true if the source code of the editor contains a messages section; false if the source code of the editor does not contain a messages section.

isDependenciesSectionPresent

public boolean isDependenciesSectionPresent()
Gets a flag indicating that the source code of the editor contains a dependencies section.

Returns:
true if the source code of the editor contains a dependencies section; false if the source code of the editor does not contain a dependencies section.

isPropertiesSectionPresent

public boolean isPropertiesSectionPresent()
Gets a flag indicating that the source code of the editor contains a properties section.

Returns:
true if the source code of the editor contains a properties section; false if the source code of the editor does not contain a properties section.


Copyright © 2005-2009 The JOMC Project. All Rights Reserved.