jdk/src/share/classes/sun/management/snmp/jvmmib/JvmCompilationMeta.java
author mchung
Tue, 17 Jan 2012 15:55:40 -0800
changeset 11530 a9d059c15b80
parent 5506 202f599c92aa
child 14342 8435a30053c1
permissions -rw-r--r--
7117570: Warnings in sun.mangement.* and its subpackages Reviewed-by: mchung, dsamersoff Contributed-by: kurchi.subhra.hazra@oracle.com
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
     1
/*
5506
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 2
diff changeset
     2
 * Copyright (c) 2003, 2004, Oracle and/or its affiliates. All rights reserved.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
     3
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
90ce3da70b43 Initial load
duke
parents:
diff changeset
     4
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
     5
 * This code is free software; you can redistribute it and/or modify it
90ce3da70b43 Initial load
duke
parents:
diff changeset
     6
 * under the terms of the GNU General Public License version 2 only, as
5506
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 2
diff changeset
     7
 * published by the Free Software Foundation.  Oracle designates this
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
     8
 * particular file as subject to the "Classpath" exception as provided
5506
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 2
diff changeset
     9
 * by Oracle in the LICENSE file that accompanied this code.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    10
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
    11
 * This code is distributed in the hope that it will be useful, but WITHOUT
90ce3da70b43 Initial load
duke
parents:
diff changeset
    12
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
90ce3da70b43 Initial load
duke
parents:
diff changeset
    13
 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
90ce3da70b43 Initial load
duke
parents:
diff changeset
    14
 * version 2 for more details (a copy is included in the LICENSE file that
90ce3da70b43 Initial load
duke
parents:
diff changeset
    15
 * accompanied this code).
90ce3da70b43 Initial load
duke
parents:
diff changeset
    16
 *
90ce3da70b43 Initial load
duke
parents:
diff changeset
    17
 * You should have received a copy of the GNU General Public License version
90ce3da70b43 Initial load
duke
parents:
diff changeset
    18
 * 2 along with this work; if not, write to the Free Software Foundation,
90ce3da70b43 Initial load
duke
parents:
diff changeset
    19
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    20
 *
5506
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 2
diff changeset
    21
 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 2
diff changeset
    22
 * or visit www.oracle.com if you need additional information or have any
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 2
diff changeset
    23
 * questions.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    24
 */
90ce3da70b43 Initial load
duke
parents:
diff changeset
    25
90ce3da70b43 Initial load
duke
parents:
diff changeset
    26
package sun.management.snmp.jvmmib;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    27
90ce3da70b43 Initial load
duke
parents:
diff changeset
    28
//
90ce3da70b43 Initial load
duke
parents:
diff changeset
    29
// Generated by mibgen version 5.0 (06/02/03) when compiling JVM-MANAGEMENT-MIB in standard metadata mode.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    30
//
90ce3da70b43 Initial load
duke
parents:
diff changeset
    31
90ce3da70b43 Initial load
duke
parents:
diff changeset
    32
// java imports
90ce3da70b43 Initial load
duke
parents:
diff changeset
    33
//
90ce3da70b43 Initial load
duke
parents:
diff changeset
    34
import java.io.Serializable;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    35
90ce3da70b43 Initial load
duke
parents:
diff changeset
    36
// jmx imports
90ce3da70b43 Initial load
duke
parents:
diff changeset
    37
//
90ce3da70b43 Initial load
duke
parents:
diff changeset
    38
import javax.management.MBeanServer;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    39
import com.sun.jmx.snmp.SnmpCounter;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    40
import com.sun.jmx.snmp.SnmpCounter64;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    41
import com.sun.jmx.snmp.SnmpGauge;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    42
import com.sun.jmx.snmp.SnmpInt;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    43
import com.sun.jmx.snmp.SnmpUnsignedInt;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    44
import com.sun.jmx.snmp.SnmpIpAddress;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    45
import com.sun.jmx.snmp.SnmpTimeticks;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    46
import com.sun.jmx.snmp.SnmpOpaque;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    47
import com.sun.jmx.snmp.SnmpString;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    48
import com.sun.jmx.snmp.SnmpStringFixed;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    49
import com.sun.jmx.snmp.SnmpOid;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    50
import com.sun.jmx.snmp.SnmpNull;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    51
import com.sun.jmx.snmp.SnmpValue;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    52
import com.sun.jmx.snmp.SnmpVarBind;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    53
import com.sun.jmx.snmp.SnmpStatusException;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    54
90ce3da70b43 Initial load
duke
parents:
diff changeset
    55
// jdmk imports
90ce3da70b43 Initial load
duke
parents:
diff changeset
    56
//
90ce3da70b43 Initial load
duke
parents:
diff changeset
    57
import com.sun.jmx.snmp.agent.SnmpMib;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    58
import com.sun.jmx.snmp.agent.SnmpMibGroup;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    59
import com.sun.jmx.snmp.agent.SnmpStandardObjectServer;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    60
import com.sun.jmx.snmp.agent.SnmpStandardMetaServer;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    61
import com.sun.jmx.snmp.agent.SnmpMibSubRequest;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    62
import com.sun.jmx.snmp.agent.SnmpMibTable;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    63
import com.sun.jmx.snmp.EnumRowStatus;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    64
import com.sun.jmx.snmp.SnmpDefinitions;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    65
90ce3da70b43 Initial load
duke
parents:
diff changeset
    66
/**
90ce3da70b43 Initial load
duke
parents:
diff changeset
    67
 * The class is used for representing SNMP metadata for the "JvmCompilation" group.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    68
 * The group is defined with the following oid: 1.3.6.1.4.1.42.2.145.3.163.1.1.5.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    69
 */
90ce3da70b43 Initial load
duke
parents:
diff changeset
    70
public class JvmCompilationMeta extends SnmpMibGroup
90ce3da70b43 Initial load
duke
parents:
diff changeset
    71
     implements Serializable, SnmpStandardMetaServer {
90ce3da70b43 Initial load
duke
parents:
diff changeset
    72
11530
a9d059c15b80 7117570: Warnings in sun.mangement.* and its subpackages
mchung
parents: 5506
diff changeset
    73
    static final long serialVersionUID = -95492874115033638L;
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    74
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
    75
     * Constructor for the metadata associated to "JvmCompilation".
90ce3da70b43 Initial load
duke
parents:
diff changeset
    76
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
    77
    public JvmCompilationMeta(SnmpMib myMib, SnmpStandardObjectServer objserv) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
    78
        objectserver = objserv;
90ce3da70b43 Initial load
duke
parents:
diff changeset
    79
        try {
90ce3da70b43 Initial load
duke
parents:
diff changeset
    80
            registerObject(3);
90ce3da70b43 Initial load
duke
parents:
diff changeset
    81
            registerObject(2);
90ce3da70b43 Initial load
duke
parents:
diff changeset
    82
            registerObject(1);
90ce3da70b43 Initial load
duke
parents:
diff changeset
    83
        } catch (IllegalAccessException e) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
    84
            throw new RuntimeException(e.getMessage());
90ce3da70b43 Initial load
duke
parents:
diff changeset
    85
        }
90ce3da70b43 Initial load
duke
parents:
diff changeset
    86
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
    87
90ce3da70b43 Initial load
duke
parents:
diff changeset
    88
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
    89
     * Get the value of a scalar variable
90ce3da70b43 Initial load
duke
parents:
diff changeset
    90
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
    91
    public SnmpValue get(long var, Object data)
90ce3da70b43 Initial load
duke
parents:
diff changeset
    92
        throws SnmpStatusException {
90ce3da70b43 Initial load
duke
parents:
diff changeset
    93
        switch((int)var) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
    94
            case 3:
90ce3da70b43 Initial load
duke
parents:
diff changeset
    95
                return new SnmpInt(node.getJvmJITCompilerTimeMonitoring());
90ce3da70b43 Initial load
duke
parents:
diff changeset
    96
90ce3da70b43 Initial load
duke
parents:
diff changeset
    97
            case 2:
90ce3da70b43 Initial load
duke
parents:
diff changeset
    98
                return new SnmpCounter64(node.getJvmJITCompilerTimeMs());
90ce3da70b43 Initial load
duke
parents:
diff changeset
    99
90ce3da70b43 Initial load
duke
parents:
diff changeset
   100
            case 1:
90ce3da70b43 Initial load
duke
parents:
diff changeset
   101
                return new SnmpString(node.getJvmJITCompilerName());
90ce3da70b43 Initial load
duke
parents:
diff changeset
   102
90ce3da70b43 Initial load
duke
parents:
diff changeset
   103
            default:
90ce3da70b43 Initial load
duke
parents:
diff changeset
   104
                break;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   105
        }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   106
        throw new SnmpStatusException(SnmpStatusException.noSuchObject);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   107
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   108
90ce3da70b43 Initial load
duke
parents:
diff changeset
   109
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   110
     * Set the value of a scalar variable
90ce3da70b43 Initial load
duke
parents:
diff changeset
   111
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   112
    public SnmpValue set(SnmpValue x, long var, Object data)
90ce3da70b43 Initial load
duke
parents:
diff changeset
   113
        throws SnmpStatusException {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   114
        switch((int)var) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   115
            case 3:
90ce3da70b43 Initial load
duke
parents:
diff changeset
   116
                throw new SnmpStatusException(SnmpStatusException.snmpRspNotWritable);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   117
90ce3da70b43 Initial load
duke
parents:
diff changeset
   118
            case 2:
90ce3da70b43 Initial load
duke
parents:
diff changeset
   119
                throw new SnmpStatusException(SnmpStatusException.snmpRspNotWritable);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   120
90ce3da70b43 Initial load
duke
parents:
diff changeset
   121
            case 1:
90ce3da70b43 Initial load
duke
parents:
diff changeset
   122
                throw new SnmpStatusException(SnmpStatusException.snmpRspNotWritable);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   123
90ce3da70b43 Initial load
duke
parents:
diff changeset
   124
            default:
90ce3da70b43 Initial load
duke
parents:
diff changeset
   125
                break;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   126
        }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   127
        throw new SnmpStatusException(SnmpStatusException.snmpRspNotWritable);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   128
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   129
90ce3da70b43 Initial load
duke
parents:
diff changeset
   130
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   131
     * Check the value of a scalar variable
90ce3da70b43 Initial load
duke
parents:
diff changeset
   132
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   133
    public void check(SnmpValue x, long var, Object data)
90ce3da70b43 Initial load
duke
parents:
diff changeset
   134
        throws SnmpStatusException {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   135
        switch((int) var) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   136
            case 3:
90ce3da70b43 Initial load
duke
parents:
diff changeset
   137
                throw new SnmpStatusException(SnmpStatusException.snmpRspNotWritable);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   138
90ce3da70b43 Initial load
duke
parents:
diff changeset
   139
            case 2:
90ce3da70b43 Initial load
duke
parents:
diff changeset
   140
                throw new SnmpStatusException(SnmpStatusException.snmpRspNotWritable);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   141
90ce3da70b43 Initial load
duke
parents:
diff changeset
   142
            case 1:
90ce3da70b43 Initial load
duke
parents:
diff changeset
   143
                throw new SnmpStatusException(SnmpStatusException.snmpRspNotWritable);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   144
90ce3da70b43 Initial load
duke
parents:
diff changeset
   145
            default:
90ce3da70b43 Initial load
duke
parents:
diff changeset
   146
                throw new SnmpStatusException(SnmpStatusException.snmpRspNotWritable);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   147
        }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   148
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   149
90ce3da70b43 Initial load
duke
parents:
diff changeset
   150
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   151
     * Allow to bind the metadata description to a specific object.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   152
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   153
    protected void setInstance(JvmCompilationMBean var) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   154
        node = var;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   155
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   156
90ce3da70b43 Initial load
duke
parents:
diff changeset
   157
90ce3da70b43 Initial load
duke
parents:
diff changeset
   158
    // ------------------------------------------------------------
90ce3da70b43 Initial load
duke
parents:
diff changeset
   159
    //
90ce3da70b43 Initial load
duke
parents:
diff changeset
   160
    // Implements the "get" method defined in "SnmpMibGroup".
90ce3da70b43 Initial load
duke
parents:
diff changeset
   161
    // See the "SnmpMibGroup" Javadoc API for more details.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   162
    //
90ce3da70b43 Initial load
duke
parents:
diff changeset
   163
    // ------------------------------------------------------------
90ce3da70b43 Initial load
duke
parents:
diff changeset
   164
90ce3da70b43 Initial load
duke
parents:
diff changeset
   165
    public void get(SnmpMibSubRequest req, int depth)
90ce3da70b43 Initial load
duke
parents:
diff changeset
   166
        throws SnmpStatusException {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   167
        objectserver.get(this,req,depth);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   168
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   169
90ce3da70b43 Initial load
duke
parents:
diff changeset
   170
90ce3da70b43 Initial load
duke
parents:
diff changeset
   171
    // ------------------------------------------------------------
90ce3da70b43 Initial load
duke
parents:
diff changeset
   172
    //
90ce3da70b43 Initial load
duke
parents:
diff changeset
   173
    // Implements the "set" method defined in "SnmpMibGroup".
90ce3da70b43 Initial load
duke
parents:
diff changeset
   174
    // See the "SnmpMibGroup" Javadoc API for more details.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   175
    //
90ce3da70b43 Initial load
duke
parents:
diff changeset
   176
    // ------------------------------------------------------------
90ce3da70b43 Initial load
duke
parents:
diff changeset
   177
90ce3da70b43 Initial load
duke
parents:
diff changeset
   178
    public void set(SnmpMibSubRequest req, int depth)
90ce3da70b43 Initial load
duke
parents:
diff changeset
   179
        throws SnmpStatusException {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   180
        objectserver.set(this,req,depth);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   181
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   182
90ce3da70b43 Initial load
duke
parents:
diff changeset
   183
90ce3da70b43 Initial load
duke
parents:
diff changeset
   184
    // ------------------------------------------------------------
90ce3da70b43 Initial load
duke
parents:
diff changeset
   185
    //
90ce3da70b43 Initial load
duke
parents:
diff changeset
   186
    // Implements the "check" method defined in "SnmpMibGroup".
90ce3da70b43 Initial load
duke
parents:
diff changeset
   187
    // See the "SnmpMibGroup" Javadoc API for more details.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   188
    //
90ce3da70b43 Initial load
duke
parents:
diff changeset
   189
    // ------------------------------------------------------------
90ce3da70b43 Initial load
duke
parents:
diff changeset
   190
90ce3da70b43 Initial load
duke
parents:
diff changeset
   191
    public void check(SnmpMibSubRequest req, int depth)
90ce3da70b43 Initial load
duke
parents:
diff changeset
   192
        throws SnmpStatusException {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   193
        objectserver.check(this,req,depth);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   194
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   195
90ce3da70b43 Initial load
duke
parents:
diff changeset
   196
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   197
     * Returns true if "arc" identifies a scalar object.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   198
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   199
    public boolean isVariable(long arc) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   200
90ce3da70b43 Initial load
duke
parents:
diff changeset
   201
        switch((int)arc) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   202
            case 3:
90ce3da70b43 Initial load
duke
parents:
diff changeset
   203
            case 2:
90ce3da70b43 Initial load
duke
parents:
diff changeset
   204
            case 1:
90ce3da70b43 Initial load
duke
parents:
diff changeset
   205
                return true;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   206
            default:
90ce3da70b43 Initial load
duke
parents:
diff changeset
   207
                break;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   208
        }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   209
        return false;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   210
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   211
90ce3da70b43 Initial load
duke
parents:
diff changeset
   212
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   213
     * Returns true if "arc" identifies a readable scalar object.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   214
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   215
    public boolean isReadable(long arc) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   216
90ce3da70b43 Initial load
duke
parents:
diff changeset
   217
        switch((int)arc) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   218
            case 3:
90ce3da70b43 Initial load
duke
parents:
diff changeset
   219
            case 2:
90ce3da70b43 Initial load
duke
parents:
diff changeset
   220
            case 1:
90ce3da70b43 Initial load
duke
parents:
diff changeset
   221
                return true;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   222
            default:
90ce3da70b43 Initial load
duke
parents:
diff changeset
   223
                break;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   224
        }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   225
        return false;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   226
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   227
90ce3da70b43 Initial load
duke
parents:
diff changeset
   228
90ce3da70b43 Initial load
duke
parents:
diff changeset
   229
    // ------------------------------------------------------------
90ce3da70b43 Initial load
duke
parents:
diff changeset
   230
    //
90ce3da70b43 Initial load
duke
parents:
diff changeset
   231
    // Implements the "skipVariable" method defined in "SnmpMibGroup".
90ce3da70b43 Initial load
duke
parents:
diff changeset
   232
    // See the "SnmpMibGroup" Javadoc API for more details.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   233
    //
90ce3da70b43 Initial load
duke
parents:
diff changeset
   234
    // ------------------------------------------------------------
90ce3da70b43 Initial load
duke
parents:
diff changeset
   235
90ce3da70b43 Initial load
duke
parents:
diff changeset
   236
    public boolean  skipVariable(long var, Object data, int pduVersion) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   237
        switch((int)var) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   238
            case 2:
90ce3da70b43 Initial load
duke
parents:
diff changeset
   239
                if (pduVersion==SnmpDefinitions.snmpVersionOne) return true;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   240
                break;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   241
            default:
90ce3da70b43 Initial load
duke
parents:
diff changeset
   242
                break;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   243
        }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   244
        return super.skipVariable(var,data,pduVersion);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   245
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   246
90ce3da70b43 Initial load
duke
parents:
diff changeset
   247
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   248
     * Return the name of the attribute corresponding to the SNMP variable identified by "id".
90ce3da70b43 Initial load
duke
parents:
diff changeset
   249
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   250
    public String getAttributeName(long id)
90ce3da70b43 Initial load
duke
parents:
diff changeset
   251
        throws SnmpStatusException {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   252
        switch((int)id) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   253
            case 3:
90ce3da70b43 Initial load
duke
parents:
diff changeset
   254
                return "JvmJITCompilerTimeMonitoring";
90ce3da70b43 Initial load
duke
parents:
diff changeset
   255
90ce3da70b43 Initial load
duke
parents:
diff changeset
   256
            case 2:
90ce3da70b43 Initial load
duke
parents:
diff changeset
   257
                return "JvmJITCompilerTimeMs";
90ce3da70b43 Initial load
duke
parents:
diff changeset
   258
90ce3da70b43 Initial load
duke
parents:
diff changeset
   259
            case 1:
90ce3da70b43 Initial load
duke
parents:
diff changeset
   260
                return "JvmJITCompilerName";
90ce3da70b43 Initial load
duke
parents:
diff changeset
   261
90ce3da70b43 Initial load
duke
parents:
diff changeset
   262
            default:
90ce3da70b43 Initial load
duke
parents:
diff changeset
   263
                break;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   264
        }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   265
        throw new SnmpStatusException(SnmpStatusException.noSuchObject);
90ce3da70b43 Initial load
duke
parents:
diff changeset
   266
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   267
90ce3da70b43 Initial load
duke
parents:
diff changeset
   268
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   269
     * Returns true if "arc" identifies a table object.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   270
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   271
    public boolean isTable(long arc) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   272
90ce3da70b43 Initial load
duke
parents:
diff changeset
   273
        switch((int)arc) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   274
            default:
90ce3da70b43 Initial load
duke
parents:
diff changeset
   275
                break;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   276
        }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   277
        return false;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   278
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   279
90ce3da70b43 Initial load
duke
parents:
diff changeset
   280
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   281
     * Returns the table object identified by "arc".
90ce3da70b43 Initial load
duke
parents:
diff changeset
   282
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   283
    public SnmpMibTable getTable(long arc) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   284
        return null;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   285
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   286
90ce3da70b43 Initial load
duke
parents:
diff changeset
   287
    /**
90ce3da70b43 Initial load
duke
parents:
diff changeset
   288
     * Register the group's SnmpMibTable objects with the meta-data.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   289
     */
90ce3da70b43 Initial load
duke
parents:
diff changeset
   290
    public void registerTableNodes(SnmpMib mib, MBeanServer server) {
90ce3da70b43 Initial load
duke
parents:
diff changeset
   291
    }
90ce3da70b43 Initial load
duke
parents:
diff changeset
   292
90ce3da70b43 Initial load
duke
parents:
diff changeset
   293
    protected JvmCompilationMBean node;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   294
    protected SnmpStandardObjectServer objectserver = null;
90ce3da70b43 Initial load
duke
parents:
diff changeset
   295
}