简体   繁体   English

Java中的“Chunk :: new”中的“::”(双冒号)运算符是什么意思?

[英]what does “::” (double colon) operator mean in “Chunk::new” in Java?

I am getting hs_err_pid fatal logs from a tomcat process, and inside the log it says 我从tomcat进程获取hs_err_pid致命日志 ,并在日志内部说

#
# A fatal error has been detected by the Java Runtime Environment:
#
# java.lang.OutOfMemoryError: requested 1035152 bytes for Chunk::new. Out of swap space?
#
#  Internal Error (allocation.cpp:215), pid=2060, tid=3980
#  Error: Chunk::new
#
# JRE version: 6.0_21-b07
# Java VM: Java HotSpot(TM) Server VM (17.0-b17 mixed mode windows-x86 )
# If you would like to submit a bug report, please visit:
#   http://java.sun.com/webapps/bugreport/crash.jsp
#

My question isn't specifically about the OutOfMemoryError, but about how to interpret the Chunk::new phrase. 我的问题不是关于OutOfMemoryError,而是关于如何解释Chunk::new短语。

I see here that apparently the double colon is an operator in Java, but I don't know for sure what it does. 在这里看到,显然双冒号是Java中的运算符,但我不确定它的作用。 Would that have something to do with my situation? 这会与我的情况有关吗?

It doesn't mean anything in Java before version 8 (see this question ). 它在版本8之前的Java中没有任何意义(请参阅此问题 )。

What you're seeing refers to C++ code. 你所看到的是指C ++代码。 The first word is the class name, second is the method name. 第一个词是类名,第二个是方法名。 The :: itself is called the Scope resolution operator . ::本身称为范围解析运算符

The error you're getting is from the C++ code of the JVM itself. 您获得的错误来自JVM本身的C ++代码。

This indicates Java has failed to acquire more memory from the operating system. 这表明Java无法从操作系统获取更多内存。

JVM you are using is developed on C++. 您正在使用的JVM是在C ++上开发的。 but JVM things are vendor specific. 但JVM的东西是供应商特定的。

There is nothing to do with :: this operator. 与此运算符无关。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM