Jump to: navigation, search

Dali/Indigo/DaliQuickFixes

< Dali‎ | Indigo

Quick Fixes

  • Can you turn off quick assists/quick fixes?
  • Quick fixes for changing the preference error level for all of our problems? Or maybe just important ones? Maybe the quick fix just opens our error/warning preferences
  • Will need to extend both o.e.jdt.ui.quickFixProcessors and o.e.wst.sse.ui.quickFixProcessor
  • Need integer ids on all of our problems for the jdt quick fix processor framework to work properly. Have to set this attribute on the org.eclipse.wst.validation.internal.provisional.core.IMessage: message.setAttribute(IJavaModelMarker.ID, id);


Project

  • Create or specify connection
  • Connect to DB (Connection is not active)
  • Create a persistence.xml (no persistence.xml file found in project)
  • Upgrade orm.xml and persistence.xml document

Types

  • Validation - Class is mapped but is not included in any persistence unit - applies to java
    • Add class to persistence.xml
    • Unmap class - remove all JPA annotations from the type and all attributes.
  • Create new Entity (Use New Entity wizard) for targetEntity references which cannot be resolved - apply to both java and orm.xml
  • Insert @Table for unresolved default table on an Entity

Attributes

  • Create the corresponding relationship attribute and mapping (mappedBy that does not resolve)
  • Create the corresponding relationship mapping (mappedBy has invalid mapping type for this relationship)
  • Insert @Column for unresolved default column a basic mapping
    • private int foo;
      • Error appears on foo
      • Quick fix options:
        • Insert '@Column(name="BAR")'
        • Insert '@Column(name="OTHER")'
    • @Column private int foo;
      • Error appears on @Column
      • Quick fix options:
        • Insert 'name="BAR"'
        • Insert 'name="OTHER"'
    • @Column(name="foo") private int foo;
      • Error appears on "foo"
      • Quick fix options:
        • Change to 'BAR'
        • Change to 'OTHER'