Back to project page bad.
The source code is released under:
Copyright (C) 2013 Madis Pink Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Softwa...
If you think the Android project bad listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package com.madisp.bad.expr; /*w w w. j a v a2s. c om*/ import com.madisp.bad.eval.BadConverter; import com.madisp.bad.eval.Scope; import com.madisp.bad.eval.Watcher; /** * Created with IntelliJ IDEA. * User: madis * Date: 5/7/13 * Time: 11:12 AM */ public class DivisionExpression implements Expression { private final Expression left; private final Expression right; public DivisionExpression(Expression left, Expression right) { this.left = left; this.right = right; } @Override public Object value(Scope scope) { return BadConverter.integer(left.value(scope)) / BadConverter.integer(right.value(scope)); } @Override public void addWatcher(Scope scope, Watcher w) { left.addWatcher(scope, w); right.addWatcher(scope, w); } }