dmolony-DiskBrowser/src/com/bytezone/diskbrowser/visicalc/Cos.java

22 lines
815 B
Java

package com.bytezone.diskbrowser.visicalc;
// ---------------------------------------------------------------------------------//
class Cos extends ValueFunction
// ---------------------------------------------------------------------------------//
{
// ---------------------------------------------------------------------------------//
Cos (Cell cell, String text)
// ---------------------------------------------------------------------------------//
{
super (cell, text);
assert text.startsWith ("@COS(") : text;
}
// ---------------------------------------------------------------------------------//
@Override
public double calculateValue ()
// ---------------------------------------------------------------------------------//
{
return Math.cos (source.getDouble ());
}
}