本文附带的下载实例代码可以使您安装并测试一个运行样本。
The example code available for download with this article will enable you to install and test a working sample. The example was built and tested using the following software and hardware.
接下来的部分将描述他们是如何运行的,并通过实例代码演示了一些特殊的设计点。
Their operation is described in the next sections followed by example code to illustrate particular design points.
当工具包向导生长一个工程时,向导会为三个关键方法提供部分代码或实例代码,如表1 所示。
When the toolkit wizard creates a project, it provides stubs or sample code for three key methods, as shown in Table 1.
我建议您可以在移植向导中尝试实例代码以确保其是否正常工作,并且查看您的应用程序以减少潜在的问题。
I would ask you to try some sample code in the migration wizard to ensure that it is working properly, and take an additional look at your application to eliminate any potential issues.
由于不能pickle类实例代码,因此可以添加、更改和除去方法,而不会影响现有的经过pickle的实例。
Because a class instance's code is not pickled, you can add, change, and remove methods without impacting existing pickled instances.
如果你已经下载了本书的实例代码,它们中的许多小程序可以用scala命令来运行,比如scala filename.scala。
If you've downloaded the example code for the book, many of the smaller examples can be run using the scala command, e.g., scala filename.scala.
如图6所示,这些视图提供了关于类,实例,包以及代码区域等等的详细信息。
Illustrated in Figure 6, these views provide details on classes, instances, packages, code coverage, and so on.
清单2中展示的代码片段使用实例值加载表单字段。
The code snippet shown in listing 2 loads the form fields with instance values.
清单3显示的代码片段根据流程实例ID获取事件处理程序。
Listing 3 shows the code snippet getting the event handler by a process instance ID.
更有可能是其他用于创建类实例的代码导致了过度的内存占用。
Most likely, other code is responsible for creating instances of the classes that have caused the extensive memory usage.
在表4中所示的实例中,相同的代码用于识别分析模型中要进行转换的单元。
In the example shown in Table 4, the same code is used to identify elements in the analysis model that should have been transformed.
类型有两种“用户”:继承类型,以及使用类型实例的代码。
There are two kinds of “users” of a type: derived types and code that works with instances of the type.
在一个理想的小敏捷项目之中,您有小的交接,因为团队成员要扮演所有的项目角色(编写实例,开发代码,测试,等等)。
In an ideal small agile project, you would have minimal hand-offs, because team members tend to take on all project roles (write stories, develop code, test, and so on).
清单4给出安装s3fs实例的代码。
不用惊讶,run方法包含我编写的、用来创建这些对象的新实例的代码,而main方法则调用run方法。
Not surprisingly, the run method contains the code I wrote to create new instances of those objects and the main method calls the run method.
参见每一章节代码实例中的README. txt可以获取更多细节。
See the README.txt files in each chapter's code examples for more details.
清单6显示了将XML消息反系列化到Product实例的代码。
Listing 6 shows the code to deserialize the XML message into a Product instance.
清单7给出了获得calendar类新实例的代码,从而得到一天中的具体时间(以24小时的格式返回),然后根据这个时间组合出一条简单的欢迎词。
Listing 7 demonstrates code to get a new instance of the Calendar class, obtain the hour of the day (which is returned in a 24-hour format), and then put together a simple greeting based on that hour.
下面是一组代码实例,显示了如何处理userdefinedpushdownmethodsimpl类中的各种形式的返回值。
Below is a set of code examples that show how to handle various forms of the return value in the UserDefinedPushDownMethodsImpl class.
特别是,VisualStudio提供创建ComponentResourceManager实例的代码,这会加载正确的资源集,并分配所有必要的控件值。
In particular, Visual Studio supplies the code to create an instance of the ComponentResourceManager, which loads the proper set of resources and assigns all the necessary control values.
清单2显示的是使用BusinessFlowManagerAPI获取流程实例ID的代码片段。
Listing 2 shows the code snippet to get the process instance ID using the Business Flow Manager API.
清单3显示了创建WSRelationalPushDownHelper的代码实例。
Listing 3 shows a code example that creates a WSRelationalPushDownHelper.
并用一个简短的代码实例回顾了如何消费Web服务,即JAX - rpc子集api。
I also reviewed how to consume Web services, the JAX-RPC subset API, with a short code example included.
实际上,它与清单8非常类似,不过增加了一行创建pers1实例的代码。
In fact, it looks just like Listing 8, but with an added line creating the pers1 instance.
为了设定代码执行的上下文,self变量要设置为执行代码时所在的对象实例,以使得代码可以访问对象实例的变量。
In order to set the context, the variable self is set to the instance while the code is executing, giving the code access to the instance's variables.
这意味着任何用户都可以执行被编写用来创建auction类实例的代码,但只有拥有该实例的用户可以执行用来修改它的代码。
This means that any user can execute the code written to create an Auction class instance, but only the user who owns that instance may execute code designed to modify it.
工具集还在VisualStudio 2010中安装了“管理器”模块,在其中开发者可以浏览各种组成dynamics CRM实例的代码。
The toolkit also installs an "Explorer" module into Visual Studio 2010 where developers can browse the various artifacts that make up their Dynamics CRM instance.
再一次,任何用户都可以执行被编写用来创建bid类实例的代码,但只有拥有该实例的用户会被授予修改该实例的许可权。
Again, any user can execute the code written to create an instance of a Bid class, but only a user who owns that instance will be given permission to modify it.
respond _ to方法接受单个代码块,并传递一个实例变量(标为wants)到代码块。
The respond_to method accepts a single code block and passes one instance variable (labeled wants) into the code block.
respond _ to方法接受单个代码块,并传递一个实例变量(标为wants)到代码块。
The respond_to method accepts a single code block and passes one instance variable (labeled wants) into the code block.
应用推荐