77 static bool is_attach_supported() { return !DisableAttachMechanism; } 78 79 // platform specific initialization 80 static int pd_init(); 81 82 // platform specific operation 83 static AttachOperationFunctionInfo* pd_find_operation(const char* name); 84 85 // platform specific flag change 86 static jint pd_set_flag(AttachOperation* op, outputStream* out); 87 88 // platform specific detachall 89 static void pd_detachall(); 90 91 // platform specific data dump 92 static void pd_data_dump(); 93 94 // dequeue the next operation 95 static AttachOperation* dequeue(); 96 #endif // !INCLUDE_SERVICES 97 }; 98 99 #if INCLUDE_SERVICES 100 class AttachOperation: public CHeapObj<mtInternal> { 101 public: 102 enum { 103 name_length_max = 16, // maximum length of name 104 arg_length_max = 1024, // maximum length of argument 105 arg_count_max = 3 // maximum number of arguments 106 }; 107 108 // name of special operation that can be enqueued when all 109 // clients detach 110 static char* detachall_operation_name() { return (char*)"detachall"; } 111 112 private: 113 char _name[name_length_max+1]; 114 char _arg[arg_count_max][arg_length_max+1]; 115 116 public: | 77 static bool is_attach_supported() { return !DisableAttachMechanism; } 78 79 // platform specific initialization 80 static int pd_init(); 81 82 // platform specific operation 83 static AttachOperationFunctionInfo* pd_find_operation(const char* name); 84 85 // platform specific flag change 86 static jint pd_set_flag(AttachOperation* op, outputStream* out); 87 88 // platform specific detachall 89 static void pd_detachall(); 90 91 // platform specific data dump 92 static void pd_data_dump(); 93 94 // dequeue the next operation 95 static AttachOperation* dequeue(); 96 #endif // !INCLUDE_SERVICES 97 98 private: 99 static bool init_error(TRAPS); 100 }; 101 102 #if INCLUDE_SERVICES 103 class AttachOperation: public CHeapObj<mtInternal> { 104 public: 105 enum { 106 name_length_max = 16, // maximum length of name 107 arg_length_max = 1024, // maximum length of argument 108 arg_count_max = 3 // maximum number of arguments 109 }; 110 111 // name of special operation that can be enqueued when all 112 // clients detach 113 static char* detachall_operation_name() { return (char*)"detachall"; } 114 115 private: 116 char _name[name_length_max+1]; 117 char _arg[arg_count_max][arg_length_max+1]; 118 119 public: |