Part of Slepp's ProjectsPastebinTURLImagebinFilebin
Feedback -- English French German Japanese
Create Upload Newest Tools Donate
Sign In | Create Account

Advertising

advertising

related pastes to tag 'groovy'

2053745 - Derived Property Tests: java hibernate grails groovy gorm
  1. import org.codehaus.groovy.grails.commons.ApplicationHolder as AH
  2.  
  3. /* Purpose: get info on Hibernate's interaction between derived properties and cache */
  4. /* Finds:
  5.   The derived property is always searchable, as this involved a database search.
  6.   The derived property of an object will always be null if the version that was saved is still in the cache
  7.   How one retrieves the object, get, findBy*, findAllBy*, ... does not matter. It will still use the cached version.
  8.  
  9.  
  10.  
2053623 - Derived Property Test: java grails groovy
  1. ... domain class
  2. class ClassWithDerivedProperty {
  3.   Integer a
  4.   Integer b
  5.   Integer aTimesB
  6.  
  7.   static mapping = {
  8.     aTimesB formula: 'A*B'
  9.  
fantasy-obligation
fantasy-obligation