什么是运行时环境?
有人可以用简单的术语解释一下这意味着什么吗?是指应用程序代码运行的环境(DOS、Windows、Linux等)吗?
Can some one explain what it means in simple terms. Does it mean the environment (DOS, Windows, Linux, etc) where the application codes are run?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(8)
将其与开发环境和构建环境区分开来。
您往往会在这里找到层次结构。
运行时环境 - 执行程序所需的一切,但没有工具可以更改它。
构建环境 - 给定某人编写的一些代码,编译它或以其他方式准备放入运行时环境的可执行文件所需的一切。除非您可以看到您所构建的测试,否则构建环境几乎毫无用处,因此它们通常也包含运行。在构建中您实际上无法修改代码。
开发环境 - 编写代码、构建和测试所需的一切。代码编辑器和其他此类工具。通常还包括构建和运行。
Distinguish this from Development Environments and Build Environments.
You will tend to find a hierarchy here.
Run time environment - Everything you need to execute a program, but no tools to change it.
Build environment- Given some code written by someone, everything you need to compile it or otherwise prepare an executable that you put into a Run time environment. Build environments are pretty useless unless you can see tests what you have built, so they often include Run too. In Build you can't actually modify the code.
Development environment - Everything you need to write code, build it and test it. Code Editors and other such tools. Typically also includes Build and Run.
是的,包括所有设置(如环境变量)、公共库(!)、目录结构、网络邻居等
Yes, including all the settings (like environment variables), common libraries(!), directory structure, network neighbors e.t.c
运行时环境也可以是虚拟机,例如.NET框架的JRE(Java运行时环境)或CLR(公共语言运行时)。
你的计划的目标是什么?程序是否运行在JRE、CLR之上?或者您是否编译成由操作系统运行的二进制文件?
主要问题是你的计划的目标是什么。你的程序将如何执行?
The runtime environment can also be a virtual machine, such as the JRE (Java Runtime Environment) or CLR (Common Language Runtime) for .NET framework.
What is the target of your program? Does the program run on top of the JRE, CLR? Or are you compiling into a binary file that is run by your operating system?
The main question is what is that target of your program. How will your program be executed?
软件程序一旦执行,就处于运行时状态。在此状态下,程序可以向计算机的处理器发送指令并访问计算机的内存(RAM)和其他系统资源。
RTE 允许程序在程序员可以跟踪程序正在处理的指令并调试可能出现的任何错误的环境中运行。
虽然开发人员使用 RTE 软件来构建程序,但日常计算机用户也可以使用 RTE 程序,例如 Adobe Flash Player 等软件
来源
As soon as a software program is executed, it is in a run-time state. In this state, the program can send instructions to the computer's processor and access the computer's memory (RAM) and other system resources.
RTE allows the program to be run in an environment where the programmer can track the instructions being processed by the program and debug any errors that may arise.
While developers use RTE software to build programs, RTE programs are available to everyday computer users as well,e.g software such as Adobe Flash Player
Source
为了补充给出的其他答案,我想说运行时环境是一个支持程序/进程执行的环境。一个程序要能够执行,就需要运行时环境。运行时环境为程序/进程提供以下服务: -
简而言之,运行环境对于程序来说,就像物理环境对于我们来说一样。没有运行时环境,程序/进程就无法维持。
To add to the other answers given, I would say that Runtime environment is an environment, which supports the execution of a program/process. A program, for being able to execute, requires runtime environment. Runtime environment provides following services to the program/process :-
In short, Runtime environment is for the program, what physical environment is to us. Program/process can't sustain without runtime environment.
我正在研究编译器和运行时环境,这意味着目标计算机寄存器和内存的结构用于管理内存并维护指导执行过程所需的信息。
这三种运行环境是
I am working on compilers and the Runtime environment means ,it is the structure of the target computers registers and memory that serves to manage memory and maintain information needed to guide the execution process.
These three kind of runtime environmenta are
简单而通用的定义
我们不要让它变得如此复杂,在软件工程的背景下,运行时环境只是一个软件需要运行的环境。
例如,您可能在 Google 上搜索了GTA-V 的电脑要求,并找到了以下答案:
最低系统要求:
这些是什么?这些是您
运行 GTA-V所需的环境变量,同样的事情的另一种说法是:这是 GTA 的
运行时环境
-V。以 Node.js 为例,当您说 Node.js 是 JavaScript 运行时环境时,您只是意味着 Node.js 提供了
一切
(从软件角度)在硬件(手机、笔记本电脑、 ETC)。一切
都包括与特定硬件的操作系统的接口。技术定义
Runtime environment, primarily implements portions of an execution model.
执行模型
指定语言元素的行为
。通过应用执行模型,人们可以得出用该编程语言编写的程序的行为。好的,我知道
console.log("Hi")
在console
上向我显示hi
,但是这个行为
该特定字符串(console.log)的实现?代码执行和输出日志记录之间发生的部分或全部
底层步骤
构成了运行时环境
。Simple and Generic definition
Let's not make it so complicated, in context of software engineering a runtime environment is simply an environment that a piece of software needs to run.
For example you might have Googled PC Requirements for GTA-V and you found the following answer:
Minimum System Requirements:
What are these? These are the
environment variableswhich youneed to run GTA-V, another way to say the same thing is:This is
runtime environment
for GTA-V.Take example of Node.js, when you say Node.js is JavaScript runtime environment you simply mean that Node.js provides
everything
(from software perspective) to run JavaScriptic code on the hardware (Mobiles, Laptops, etc). Thateverything
includes interfaces to the Operating Systems of that particular hardwares.Technical definition
Runtime environment, primarily implements portions of an execution model.
The
execution model
specifies thebehavior
of elements of the language. By applying the execution model, one can derive the behavior of a program that was written in terms of that programming language.Ok I know that
console.log("Hi")
shows mehi
on theconsole
, but how thisbehaviour
of that particular string (console.log) is achieved?Some or all the
underlying steps
which were takenbetween
the execution of code and logging of the output constitueruntime environment
.它是指使软件程序能够在计算机系统上执行的软件和硬件资源的集合。运行时系统是一种复合机制,旨在提供程序执行服务,无论使用何种编程语言
It refers to the collection of software and hardware resources that enable a software program to be executed on a computer system. The runtime system is a composite mechanism designed to provide program execution services, regardless of the programming language being used