test_class.file: runelite-api/src/test/java/net/runelite/api/coords/AngleTest.java
test_class.identifier: AngleTest
test_case.body: @Test
  	public void getNearestDirection()
  	{
  		Angle angle = new Angle(512 + 10);
  		assertEquals(WEST, angle.getNearestDirection());
  
  		angle = new Angle(512 + 256 + 1);
  		assertEquals(NORTH, angle.getNearestDirection());
  	}
test_case.class_method_signature: AngleTest.getNearestDirection()
test_case.full_signature: @Test public void getNearestDirection()
test_case.identifier: getNearestDirection
test_case.invocations: assertEquals getNearestDirection assertEquals getNearestDirection
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void getNearestDirection()
focal_class.declarator: angle
focal_class.modifier: private final
focal_class.original_string: private final int angle;
focal_class.type: int
focal_class.var_name: angle
focal_class.file: runelite-api/src/main/java/net/runelite/api/coords/Angle.java
focal_class.identifier: Angle
focal_class.class_method_signature: Angle.getNearestDirection()
focal_class.full_signature: public Direction getNearestDirection()
focal_class.identifier: getNearestDirection
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: Direction
focal_class.signature: Direction getNearestDirection()
focal_method.body: public Direction getNearestDirection()
  	{
  		int round = angle >>> 9;
  		int up = angle & 256;
  		if (up != 0)
  		{
  			// round up
  			++round;
  		}
  		switch (round & 3)
  		{
  			case 0:
  				return SOUTH;
  			case 1:
  				return WEST;
  			case 2:
  				return NORTH;
  			case 3:
  				return EAST;
  			default:
  				throw new IllegalStateException();
  		}
  	}
focal_method.class_method_signature: Angle.getNearestDirection()
focal_method.full_signature: public Direction getNearestDirection()
focal_method.identifier: getNearestDirection
focal_method.modifiers: public
focal_method.parameters: ()
focal_method.return: Direction
focal_method.signature: Direction getNearestDirection()