我正在 LatLng latLng = new LatLng(mCurrentLocation.getLatitude(),
mCurrentLocation.getLongitude());
MarkerOptions markerOptions = new MarkerOptions();
markerOptions.position(latLng);
markerOptions.title("You");
mCurrLocationMarker = mGoogleMap.addMarker(markerOptions);
mCurrLocationMarker.setVisible(true);
上使用JDK 1.8
构建Java代码。在构建期间,我得到maven
。
maven上的错误堆栈跟踪:
cannot find symbol error
我认为JDK 1.8中缺少一些文件。
我在这些代码行上遇到错误
[INFO] -------------------------------------------------------------
[INFO] -------------------------------------------------------------
[ERROR] COMPILATION ERROR :
[INFO] -------------------------------------------------------------
[ERROR]
\myfiles.java:[6,24] error: cannot find symbol
[ERROR]
\myfiles.java:[7,24] error: cannot find symbol
[ERROR]
\myfiles.java:[12,24] error: cannot find symbol
[ERROR]
\myfiles.java:[67,8] error: cannot find symbol
[ERROR]
\myfiles.java:[67,36] error: cannot find symbol
[ERROR]
\myfiles.java:[82,8] error: cannot find symbol
[ERROR]
\myfiles.java:[148,8] error: cannot find symbol
[ERROR]
\myfiles.java:[150,31] error: cannot find symbol
[ERROR]
\myfiles.java:[152,31] error: cannot find symbol
[ERROR]
\myfiles.java:[199,8] error: cannot find symbol
[ERROR]
\myfiles.java:[199,42] error: cannot find symbol
[INFO] 11 errors
也得到一些警告
import sun.security.pkcs.PKCS10;
import sun.security.pkcs.PKCS10Attributes;
import sun.security.x509.CertAndKeyGen;
我正在尝试为Java 8构建这些代码。所以我只是想知道这些导入在JDK 1.8中是否正确?这也适用于JDK 1.6。是否缺少任何依赖项?有任何建议请。