title: Python equivalent of Java's getClass().getFields()
body: <p>I'm converting a piece of code from Java to Python and I don't know how to translate the following:</p>
  
  <pre><code>Field[] fields = getClass().getFields();
      for (int i = 0; i &lt; fields.length; i++ ) {
          if (fields[i].getName().startsWith((String) param){ ....
  </code></pre>