14.01.2013 Views

Oracle JHeadstart Developer's Guide - Downloads - Oracle

Oracle JHeadstart Developer's Guide - Downloads - Oracle

Oracle JHeadstart Developer's Guide - Downloads - Oracle

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

2.2.4. Creating Database Connection<br />

Create a Database Connection to the schema that contains the database tables of your<br />

application. Make sure that every developer uses the same name for the connection, and<br />

that they all make the same setting for the “Deploy Password” checkbox.<br />

2.2.5. Initializing Model Project for Business Components<br />

Suggestion: JDeveloper allows you to make an export of one or more database<br />

connections to an XML file. This XML file can then be used by other<br />

developers to import database connections, ensuring that the connections will<br />

be identical on all developer PC’s. To use this feature, go to the Connections<br />

tab, right-mouse click on the Database node, and choose “Export<br />

Connections…”<br />

Go to the Project Properties of the Model project, to the Business Components panel. Tick<br />

the checkbox ‘Initialize Project for Business Components’. Choose the Database<br />

Connection you just created.<br />

2.2.6. Optimizing ADF BC for Team Development<br />

Go to the Model project, Project Properties. On the Business Components | General<br />

panel, uncheck the property named ‘Copy Package XML Files to Class Path’.<br />

This sets the default setting to be used for new ADF Business Components project. By<br />

unchecking this, the ADF design time no longer uses package XML files to track what<br />

components are in the package, so the package XML files will not be a point of merge<br />

conflicts between team members.<br />

Suggestion: For existing projects, you can also edit this property at any time<br />

by unchecking it on the Business Components | Options panel of the project<br />

properties.<br />

2.2.7. Switching off Default Creation of ADF BC Java classes<br />

When creating entity objects, view objects and application modules, JDeveloper<br />

generates Java classes for all these components that you can use to add custom code.<br />

However, in most cases you will not add custom code to those classes, so it is better to<br />

turn off the creation of these classes since ADF Business Components does not require<br />

these classes to run your application.<br />

If later on you do need to add custom code, you can still generate the Java class by going<br />

to the “Java” tab in the editor of the business component.<br />

You can switch off the default creation of these classes by going to the Tools -><br />

Preferences menu, and choose Business Components.<br />

<strong>JHeadstart</strong> <strong>Developer's</strong> <strong>Guide</strong> Getting Started 2 - 9

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!