Archives

Apex Comparator compare multiple object fields

Sorting a list of Analysis messages first by boolean and then integer. First we will order by condition and then order. All records where condition is true is will be on top in descending order on top followed by all false condition in descending order. SummaryAnalysisMessages object to sort Compare object by condition and then […]

Rate this:

Read More

Spring EntityManager createNativeQuery return Object[]

Scenario: You are lazy and don’t want to create an @Entity class and just want to query a few columns.

Rate this:

Read More

MemCached CustomSerializingTranscoder Serialized Object

Was getting this error when I was trying to set a custom object: memCachedClient.set(“customerObj”, 3600, new Customer(“John”, “Doe”)); This occurs because the memcached client is loaded using a classloader and the serialized object class is loaded using another classloader. To fix this you must pass to the memcahed client connector factory a custom transcoder.

Rate this:

Read More