title: Passing a non static object to static method in angular 4
body: <p>I am working angular 4 application and trying to pass the current language to the toLocaleString() method. The method mathoround is static method and doesnt understand this.translation.currentLang.
  How do I pass a non static object to static method.</p>
  
  <pre><code>import { Injectable } from '@angular/core';
  import { TranslateService } from '@ngx-translate/core';
  
  @Injectable()
  export class ChartHelperService {
  
  
      constructor( private translation: TranslateService) { }
  
      static prepareChartTooltipRow(name: string, value: string, additionalStyle: string): string {
          return '&lt;tr style="background-color: initial;"&gt;&lt;td style="text-align:left;' + additionalStyle + '"&gt;&lt;b&gt;' + name +
              '&lt;/b&gt;&lt;/td&gt;' +
              '&lt;td style="text-align: right;' + additionalStyle + '"&gt;' +
              value +
              '&lt;/td&gt;&lt;/tr&gt;';
      }
  
      static showCcorYAxis(id: number): boolean {
          return !(window.innerWidth &lt; 992 &amp;&amp; id !== 0);
      }
  
      static mathRound(input: number): string {
          return Math.round(input).toLocaleString(this.translation.currentLang, { maximumFractionDigits: 0 });
      }
  
  }
  </code></pre>