PageRenderTime 11ms CodeModel.GetById 8ms app.highlight 1ms RepoModel.GetById 1ms app.codeStats 0ms

/ocr/ocrservice/src/com/googlecode/eyesfree/env/Result.java

http://eyes-free.googlecode.com/
Java | 45 lines | 20 code | 7 blank | 18 comment | 1 complexity | dc6ef9828e351cf7657959ee37aaa0e4 MD5 | raw file
 1/*
 2 * Copyright (C) 2011 Google Inc.
 3 *
 4 * Licensed under the Apache License, Version 2.0 (the "License"); you may not
 5 * use this file except in compliance with the License. You may obtain a copy of
 6 * the License at
 7 *
 8 * http://www.apache.org/licenses/LICENSE-2.0
 9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
12 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
13 * License for the specific language governing permissions and limitations under
14 * the License.
15 */
16
17package com.googlecode.eyesfree.env;
18
19import android.graphics.Bitmap;
20import android.graphics.Rect;
21
22/**
23 * @author alanv@google.com (Alan Viverette)
24 */
25public class Result {
26    private final Bitmap mBitmap;
27    private final Rect mRect;
28
29    public Result(final Bitmap bitmap, final Rect rect) {
30        mBitmap = bitmap;
31        mRect = rect;
32    }
33
34    public Bitmap getBitmap() {
35        return mBitmap;
36    }
37
38    public Rect getBoundingBox() {
39        return mRect;
40    }
41
42    public boolean hasBoundingBox() {
43        return (mRect != null);
44    }
45}