class S3Path {

	public void appendPath( String path )
	{
		if( mKey == null )
			mKey = path ;
		else
			if( mKey.endsWith(mDelim))
				mKey = mKey + path ;
			else
				mKey = mKey + mDelim + path ;

	}

}

class S3PathTest {

  @Test
  public void testAppendPath() throws Exception {

    S3Path p = new S3Path("bucket","key");
    p.appendPath("subkey");
    assertThat("key/subkey",equalTo(p.getKey()));

  }

}