1 /* 2 * Copyright (c) 2010. The Apache Software Foundation 3 * 4 * Licensed to the Apache Software Foundation (ASF) under one 5 * or more contributor license agreements. See the NOTICE file 6 * distributed with this work for additional information 7 * regarding copyright ownership. The ASF licenses this file 8 * to you under the Apache License, Version 2.0 (the 9 * "License"); you may not use this file except in compliance 10 * with the License. You may obtain a copy of the License at 11 * 12 * http://www.apache.org/licenses/LICENSE-2.0 13 * 14 * Unless required by applicable law or agreed to in writing, software 15 * distributed under the License is distributed on an "AS IS" BASIS, 16 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 17 * See the License for the specific language governing permissions and 18 * limitations under the License. 19 */ 20 21 package org.apache.hadoop.hbase.hbql.util; 22 23 import java.lang.annotation.ElementType; 24 import java.lang.annotation.Retention; 25 import java.lang.annotation.RetentionPolicy; 26 import java.lang.annotation.Target; 27 28 /** 29 * A package attribute that captures the version of hbase that was compiled. 30 * Copied down from hadoop. All is same except name of interface. 31 */ 32 @Retention(RetentionPolicy.RUNTIME) 33 @Target(ElementType.PACKAGE) 34 public @interface VersionAnnotation { 35 36 /** 37 * Get the Hadoop version 38 * 39 * @return the version string "0.6.3-dev" 40 */ 41 String version(); 42 43 /** 44 * Get the username that compiled Hadoop. 45 */ 46 String user(); 47 48 /** 49 * Get the date when Hadoop was compiled. 50 * 51 * @return the date in unix 'date' format 52 */ 53 String date(); 54 55 /** 56 * Get the url for the subversion repository. 57 */ 58 String url(); 59 60 /** 61 * Get the subversion revision. 62 * 63 * @return the revision number as a string (eg. "451451") 64 */ 65 String revision(); 66 }