検索
ホームページJava&#&チュートリアルJava 9 で JShell ドキュメントを入手するにはどうすればよいですか?

如何在Java 9中获取JShell文档?

Java 9 では、JShell という新しい対話型ツールが導入されています。このツールは、式、クラス、インターフェイス、列挙などを実行するために使用できます。

詳細なドキュメントは JShell にあります。JShell には完全な情報のほか、内部コマンドやさまざまなオプションの使用に関する情報が含まれています。このドキュメントには、「/help」と「/?」の 2 つのコマンドを使用してアクセスできます。 JShell のドキュメントには、内部コントロールに関する情報に限定されず、Javadoc も含まれています。

次のコード スニペットでは、「 /help」コマンドを使用できます。

<strong>jshell> /help
|   Type a Java language expression, statement, or declaration.
|   Or type one of the following commands:
|   /list [<name or id>|-all|-start]
|     list the source you have typed
|   /edit <name or id>
|     edit a source entry referenced by name or id
|   /drop <name or id>
|     delete a source entry referenced by name or id
|   /save [-all|-history|-start] <file>
|     Save snippet source to a file.
|   /open <file>
|     open a file as source input
|   /vars [<name or id>|-all|-start]
|     list the declared variables and their values
|   /methods [<name or id>|-all|-start]
|     list the declared methods and their signatures
|   /types [<names or id>|-all|-start]
|     list the declared types
|   /imports
|     list the imported items
|   /exit
|     exit jshell
|   /env [-class-path <path> ] [-module-path <path>] [-add-modules <modules>] ...
|     view or change the evaluation context
|   /reset [-class-path <path>] [-module-path <path>] [-add-modules <modules>]...
|     reset jshell
|   /reload [-restore] [-quiet] [-class-path <path>] [-module-path <path>]...
|     reset and replay relevant history -- current or previous (-restore)
|   /history
|     history of what you have typed
|   /help [<command>|<subject>]
|     get information about jshell
|   /set editor|start|feedback|mode|prompt|truncation|format ...
|     set jshell configuration information
|   /? [<command>|<subject> ]
|     get information about jshell
|   /!
|     re-run last snippet
|   /
|     re-run snippet by id
|   /-
|     re-run n-th previous snippet
|   For more information type &#39;/help&#39; followed by the name of a command or a subject.
|   For example &#39;/help /list&#39; or &#39;/help intro&#39;.
|
|   Subjects:
|
|   intro
|     an introduction to the jshell tool
|   shortcuts
|     a description of keystrokes for snippet and command completion,
|     information access, and automatic code generation
|   context
|     the evaluation context options for /env /reload and /reset</strong>

JShell さまざまな既存の内部コマンドとその目的の簡単な説明を出力し、その使用方法の詳細な手順にアクセスします。これを行うには、コマンド「/help」を入力し、コマンドの詳細名 (たとえば、「/set」コマンド) を入力するだけです。

<strong>jshell> /help /set
|
|  /set
|
|   Set jshell configuration information, including:
|   the external editor to use, the start-up definitions to use, a new feedback mode,
|   the command prompt, the feedback mode to use, or the format of output.
|
|   /set editor [-wait] ...
|     Specify the command to launch for the /edit command.
|     The <command> is an operating system dependent string.
|
|   /set start <file>
|     The contents of the specified become the default start-up snippet s and commands.
|
|   /set feedback <mode>
|     Set the feedback mode describing displayed feedback for entered snippets and commands.
|
|   /set mode <mode>[<old-mode>] -command|-quiet|-delete
|     Create or update a user-defined feedback mode, optionally copying from an existing mode.
|
|   /set prompt <mode>"<prompt>" "<continuation-prompt>"
|     Set the displayed prompts for a given feedback mode.
|
|   /set truncation <mode> <length> <selector> ...
|     Set the maximum length of a displayed value.
|
|   /set format <mode> <field> "<format>" ...
|     Configure a feedback mode by setting the format of a field when the selector matches.
|
|   /set
|     Show editor, start, and feedback settings as /set commands.
|     To show the settings of any of the above, omit the set value.
|
|     To get more information about one of these forms, use /help with the form specified.
|  For example: /help /set format</strong>

3 番目の部分で入力されたコマンドを見つけて、JShell の戻り値 (/set Feedback) を次のように変更するかどうかを確認する必要があります。デフォルトのエディターを変更する (/set editor)、または JShell の起動を変更する (/set start)。

えええええ

以上がJava 9 で JShell ドキュメントを入手するにはどうすればよいですか?の詳細内容です。詳細については、PHP 中国語 Web サイトの他の関連記事を参照してください。

声明
この記事はtutorialspointで複製されています。侵害がある場合は、admin@php.cn までご連絡ください。
JVMはオペレーティングシステムAPIの違いをどのように処理しますか?JVMはオペレーティングシステムAPIの違いをどのように処理しますか?Apr 27, 2025 am 12:18 AM

JVMは、JavanativeInterface(JNI)およびJava Standard Libraryを介してオペレーティングシステムのAPIの違いを処理します。1。JNIでは、Javaコードがローカルコードを呼び出し、オペレーティングシステムAPIと直接対話できます。 2. Java Standard Libraryは統一されたAPIを提供します。これは、異なるオペレーティングシステムAPIに内部的にマッピングされ、コードがプラットフォーム間で実行されるようにします。

Java 9で導入されたモジュール性は、プラットフォームの独立性にどのように影響しますか?Java 9で導入されたモジュール性は、プラットフォームの独立性にどのように影響しますか?Apr 27, 2025 am 12:15 AM

modularitydoesnotdirectlyectlyectjava'splatformindepensence.java'splatformendepenceismaindainededainededainededaindainedaindained bythejvm、butmodularityinfluencesApplucationStructure andmanagement、間接的なインパクチャプラット形成依存性.1)

ByteCodeとは何ですか?また、Javaのプラットフォームの独立性とどのように関係していますか?ByteCodeとは何ですか?また、Javaのプラットフォームの独立性とどのように関係していますか?Apr 27, 2025 am 12:06 AM

bytecodeinjavaisthe intermediaterepresentationthateNablesplatformindepence.1)javacodeis compiledintobytecodestoredin.classfiles.2)thejvminterpretsorcompilesthisbytecodeintomachinecodeatime、

Javaがプラットフォームに依存しない言語と見なされるのはなぜですか?Javaがプラットフォームに依存しない言語と見なされるのはなぜですか?Apr 27, 2025 am 12:03 AM

javaachievesplatformedenceTheTheTheJavavirtualMachine(JVM)、これは、javacodeisisisisisissompiledIntobytecode.2)javaCodeisisisisissompiledevedevicetecode.2)

グラフィカルユーザーインターフェイス(GUI)は、Javaのプラットフォーム独立性の課題をどのように提示できますか?グラフィカルユーザーインターフェイス(GUI)は、Javaのプラットフォーム独立性の課題をどのように提示できますか?Apr 27, 2025 am 12:02 AM

Javagui開発におけるプラットフォームの独立性は課題に直面していますが、Swing、Javafx、統一外観、パフォーマンス最適化、サードパーティライブラリ、クロスプラットフォームテストを使用することで対処できます。 Javaguiの開発は、クロスプラットフォームの一貫性を提供することを目的としたAWTとSwingに依存していますが、実際の効果はオペレーティングシステムごとに異なります。ソリューションには以下が含まれます。1)SwingおよびJavafxをGUIツールキットとして使用します。 2)uimanager.setlookandfeel()を介して外観を統合します。 3)さまざまなプラットフォームに合わせてパフォーマンスを最適化します。 4)ApachepivotやSWTなどのサードパーティライブラリを使用する。 5)一貫性を確保するために、クロスプラットフォームテストを実施します。

Java開発のどの側面がプラットフォームに依存していますか?Java開発のどの側面がプラットフォームに依存していますか?Apr 26, 2025 am 12:19 AM

javadevelopmentisnotentirelylylypratform-IndopentDuetoseveralfactors.1)jvmvariationsaffectperformanceandbehavioracrossdifferentos.2)nativeLibrariesviajniintroducePlatform-specificissues.3)giaiasystemsdifferbeTioneplateplatifflics.4)

さまざまなプラットフォームでJavaコードを実行するときにパフォーマンスの違いはありますか?なぜ?さまざまなプラットフォームでJavaコードを実行するときにパフォーマンスの違いはありますか?なぜ?Apr 26, 2025 am 12:15 AM

Javaコードは、さまざまなプラットフォームで実行するときにパフォーマンスの違いがあります。 1)JVMの実装と最適化戦略は、OracleJDKやOpenJDKなどとは異なります。 2)メモリ管理やスレッドスケジューリングなどのオペレーティングシステムの特性もパフォーマンスに影響します。 3)適切なJVMを選択し、JVMパラメーターとコード最適化を調整することにより、パフォーマンスを改善できます。

Javaのプラットフォームの独立性の制限は何ですか?Javaのプラットフォームの独立性の制限は何ですか?Apr 26, 2025 am 12:10 AM

java'splatformindepentedencehaslimitationsincludingporformanceoverhead、versioncompatibulisisues、changleSwithnativeLibraryIntegration、プラットフォーム固有の機能、およびjvminStallation/maintenation。

See all articles

ホットAIツール

Undresser.AI Undress

Undresser.AI Undress

リアルなヌード写真を作成する AI 搭載アプリ

AI Clothes Remover

AI Clothes Remover

写真から衣服を削除するオンライン AI ツール。

Undress AI Tool

Undress AI Tool

脱衣画像を無料で

Clothoff.io

Clothoff.io

AI衣類リムーバー

Video Face Swap

Video Face Swap

完全無料の AI 顔交換ツールを使用して、あらゆるビデオの顔を簡単に交換できます。

ホットツール

VSCode Windows 64 ビットのダウンロード

VSCode Windows 64 ビットのダウンロード

Microsoft によって発売された無料で強力な IDE エディター

SublimeText3 Linux 新バージョン

SublimeText3 Linux 新バージョン

SublimeText3 Linux 最新バージョン

メモ帳++7.3.1

メモ帳++7.3.1

使いやすく無料のコードエディター

SublimeText3 中国語版

SublimeText3 中国語版

中国語版、とても使いやすい

mPDF

mPDF

mPDF は、UTF-8 でエンコードされた HTML から PDF ファイルを生成できる PHP ライブラリです。オリジナルの作者である Ian Back は、Web サイトから「オンザフライ」で PDF ファイルを出力し、さまざまな言語を処理するために mPDF を作成しました。 HTML2FPDF などのオリジナルのスクリプトよりも遅く、Unicode フォントを使用すると生成されるファイルが大きくなりますが、CSS スタイルなどをサポートし、多くの機能強化が施されています。 RTL (アラビア語とヘブライ語) や CJK (中国語、日本語、韓国語) を含むほぼすべての言語をサポートします。ネストされたブロックレベル要素 (P、DIV など) をサポートします。