title: How to get field names of grails command object?
body: <p>These are my Controller and Command.
  Now i would like to get all fields names.
  Here is the link to get field names of domain class
  <a href="https://stackoverflow.com/questions/15103173/get-domain-class-field-names">Get domain class field names</a>.
  But i need to get field names of Command as i am explaining below</p>
  
  <pre><code>class SocialRecruitingController 
  {
   def getFieldNames()
   {
  
   ConnectionsAdvSearchCommand.fields.each
   {it-&gt;
     log.info(it?.name+",");
  // Expecting keyword,fname,lname,title,company,school,location,country,postalCode
   }
  
  
  } 
  
  class ConnectionsAdvSearchCommand
  {
  String keyword
  
  String fname;
  String lname;
  String title;
  String company;
  String school;
  String location;
  String country;
  String postalCode;
  }
  }
  </code></pre>