EMMA Coverage Report (generated Mon Mar 20 21:34:30 PST 2006)
[all classes][com.moesol.bindings.platform_sdk.windows_api]

COVERAGE SUMMARY FOR SOURCE FILE [HPEN.java]

nameclass, %method, %block, %line, %
HPEN.java100% (1/1)100% (3/3)82%  (23/28)88%  (7/8)

COVERAGE BREAKDOWN BY CLASS AND METHOD

nameclass, %method, %block, %line, %
     
class HPEN100% (1/1)100% (3/3)82%  (23/28)88%  (7/8)
createPen (int, int, int): HPEN 100% (1/1)74%  (14/19)75%  (3/4)
HPEN (long): void 100% (1/1)100% (4/4)100% (2/2)
HPEN (long, boolean): void 100% (1/1)100% (5/5)100% (2/2)

1/*
2 * $Id: HPEN.java,v 1.1.1.5 2004/05/25 20:23:24 hastings Exp $
3 *
4 * (c) Copyright, Moebius Solutions, Inc., 2004
5 *
6 *                       All Rights Reserved
7 *
8 * This material may be reproduced by or for the U. S. Government
9 * pursuant to the copyright license under the clause at
10 * DFARS 252.227-7014 (OCT 2001).
11 */
12 
13package com.moesol.bindings.platform_sdk.windows_api;
14 
15/**
16 * @author Robert Hastings
17 *
18 * Expose Win32 HPEN.
19 */
20public class HPEN extends HGDIOBJ {
21 
22    /**
23     * @param handle
24     * @param temporary - lead detection is skipped when true
25     */
26    protected HPEN(long handle, boolean temporary) {
27        super(handle, temporary);
28    }
29 
30    /**
31     * @param handle
32     */
33    protected HPEN(long handle) {
34        super(handle);
35    }
36        public static HPEN createPen(
37          int fnPenStyle,    // pen style
38          int nWidth,        // pen width
39          int crColor   // pen color
40        ) {
41                long r = jni_createPen(fnPenStyle, nWidth, crColor);
42                if (r == 0) {
43                        throw new RuntimeException("createPen failed");
44                }
45                return new HPEN(r);
46        }
47        public static final int PS_SOLID = 0; 
48        public static final int PS_DASH = 1; 
49        public static final int PS_DOT = 2;  
50        public static final int PS_DASHDOT = 3; 
51        public static final int PS_DASHDOTDOT = 4;
52        public static final int PS_NULL = 5;
53        public static final int PS_INSIDEFRAME = 6; 
54 
55        public static final int PS_USERSTYLE = 7;
56        public static final int PS_ALTERNATE = 8;
57        public static final int PS_STYLE_MASK = 0x0000000F;
58 
59        private static native long jni_createPen(int fnPenStyle, int nWidth, int crColor);
60}

[all classes][com.moesol.bindings.platform_sdk.windows_api]
EMMA 2.0.5312 (C) Vladimir Roubtsov