KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > aspectj > runtime > reflect > UnlockSignatureImpl


1 /*******************************************************************************
2  * Copyright (c) 2006 IBM Corporation and others.
3  * All rights reserved. This program and the accompanying materials
4  * are made available under the terms of the Eclipse Public License v1.0
5  * which accompanies this distribution, and is available at
6  * http://www.eclipse.org/legal/epl-v10.html
7  *
8  * Contributors:
9  * Andy Clement - initial implementation
10  *******************************************************************************/

11
12
13 package org.aspectj.runtime.reflect;
14
15 import java.lang.reflect.Modifier JavaDoc;
16
17 import org.aspectj.lang.reflect.UnlockSignature;
18
19 class UnlockSignatureImpl extends SignatureImpl implements UnlockSignature {
20     private Class JavaDoc parameterType;
21     
22     UnlockSignatureImpl(Class JavaDoc c) {
23         super(Modifier.STATIC, "unlock", c);
24         parameterType = c;
25     }
26     
27     UnlockSignatureImpl(String JavaDoc stringRep) {
28         super(stringRep);
29     }
30
31     protected String JavaDoc createToString(StringMaker sm) {
32         if (parameterType == null) parameterType = extractType(3);
33         return "unlock("+sm.makeTypeName(parameterType)+")";
34     }
35
36     public Class JavaDoc getParameterType() {
37         if (parameterType == null) parameterType = extractType(3);
38         return parameterType;
39     }
40 }
41
Popular Tags