All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.uqbar.eclipse.jface.ReflectionLabelProvider.scala Maven / Gradle / Ivy

package org.uqbar.eclipse.jface

import org.eclipse.jface.viewers.LabelProvider
import org.uqbar.commons.utils.ReflectionUtils

class ReflectionLabelProvider(var propertyName:String) extends LabelProvider {

  override def getText(element:Object) = 
    if (propertyName != null) 
	  ReflectionUtils.invokeGetter(element, propertyName) + ""
    else
      element.toString
  
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy