C#
// Create SMTP object
Smtp mailer = new Smtp();
// Set the message fields.
mailer.From.AsString = "jdoe@domain.com";
mailer.To.AsString = "bill@domain2.com";
mailer.Subject = "Hi";
mailer.BodyPlainText = "This is test message";
// Starts logging SMTP activities into a file.
mailer.Log.Enabled = true;
mailer.Log.Filename = @"C:\log.txt";
mailer.Log.Clear();
// Specify the server to use. If your server does not require authentication,
// just omit both last parameters.
mailer.SmtpServers.Add("mail.domain.com", "jdoe", "secret");
// Attempt to connect.
mailer.Connect();
// Display the host name of the server the connection was established with.
Console.WriteLine("Connected to " + mailer.SmtpServers[mailer.GetCurrentSmtpServerIndex()].Name);
// Make sure all the recipients are ok.
if (mailer.TestSend(SendFailureThreshold.AllRecipientsFailed) != TestSendResult.OK)
{
Console.WriteLine("No recipients can receive the message.");
}// Show refused recipients if any
else if (mailer.GetRefusedRecipients().Count > 0)
{
Console.WriteLine("The following recipients failed: " + mailer.GetRefusedRecipients().ToString());
}
else
{
Console.WriteLine("All recipients are ok. Will send the message now.");
// Send e-mail. If it cannot be delivered, bounce will
// arrive to bounce@domain3.com, not to joe@domain1.com
mailer.Send("bounce@domain.com", (string)null);
Console.WriteLine("Sent to: " + mailer.GetAcceptedRecipients().ToString());
}
// Disconnect from the server
mailer.Disconnect();VB.NET
' Create SMTP object
Dim mailer As New Smtp
' Set the message fields.
mailer.From.AsString = "jdoe@domain.com"
mailer.To.AsString = "bill@domain2.com"
mailer.Subject = "Hi"
mailer.BodyPlainText = "This is test message"
' Starts logging SMTP activities into a file.
mailer.Log.Enabled = True
mailer.Log.Filename = "C:\log.txt"
mailer.Log.Clear()
' Specify the server to use. If your server does not require authentication,
' just remove last 2 parameters.
mailer.SmtpServers.Add("mail.domain.com", "jdoe", "secret")
' Attempt to connect.
mailer.Connect()
' Display the host name of the server the connection was established with.
Console.WriteLine("Connected to " + mailer.SmtpServers(mailer.GetCurrentSmtpServerIndex()).Name)
' Make sure all the recipients are ok.
If mailer.TestSend(SendFailureThreshold.AllRecipientsFailed) <> TestSendResult.OK Then
Console.WriteLine("No recipients can receive the message.")
Else
' Show refused recipients if any
If mailer.GetRefusedRecipients().Count > 0 Then
Console.WriteLine("The following recipients failed: " & mailer.GetRefusedRecipients().ToString())
Else
Console.WriteLine("All recipients are ok. Will send the message now.")
' Send e-mail. If it cannot be delivered, bounce will
' arrive to bounce@domain3.com, not to joe@domain1.com
mailer.Send("bounce@domain.com", CType(Nothing, String))
Console.WriteLine("Sent to: " + mailer.GetAcceptedRecipients().ToString())
End If
End If
' Disconnect from the server
mailer.Disconnect()

































Java 9在9月21日正式发布,同时Oracle宣布将Java新版本的发布周期调整为每半年一次。目前,Java新版本的开发也已正式进入轨道。就已公开的消息来看,下一个版本的Java预计会在2018年3月发布,版本号将会是18.3,已经规划加入的特性包括JEP 286和296。
根据reddit站点上的讨论,首先更新的是JEP 296,Valhalla预计很快也会加入进来。OpenJDK的主页面则显示,已确定要在18.3版本实现的是JEP 286和296。
JEP 296主要是将JDK仓库群(JDK Repository Forest)合并为一个仓库,旨在降低管理大量仓库群的成本。根据InfoQ之前的报道,该仓库群的合并已经完成。这些软件仓库是在OpenJDK发展史上历次分裂生成的,在OpenJDK 9及以前的版本中将会继续存在。在这次合并操作之前,OpenJDK曾分裂为多个不同的Mercurial软件仓库群,这导致了许多问题,例如不能以原子方式对多个软件仓库应用漏洞修复(Bug Fixes)。在OpenJDK合并完成后,只会有一个软件仓库,并复制在三个开发线上。为了简化仓库的管理,JDK中还创建了用于在合并和未合并版本间移动更改的工具。
JEP 286提议在Java中引入局部变量的类型推断,该JEP在2016年提出,InfoQ曾经报道过该JEP的概况和相关的开发者调查结果。该JEP旨在减少编写Java代码相关的仪式性的内容,提升开发人员的体验,同时还要保证Java语言的静态性。它会减少开发人员在声明局部变量时,没有必要的变量类型声明。如果该JEP实现的话,在声明局部变量的时候,就可以采用类似如下的方式:
var list = new ArrayList(); // infers ArrayList var stream = list.stream(); // infers Stream
这种语句只能用于带有初始化器(initializer)的局部变量、增强的for-loop中的索引以及传统for-loop中声明的局部变量。它不能用于方法声明、构造函数声明、方法返回值、字段、catch语句以及其他类型的变量声明中。
关于局部变量的类型推断,不管是JVM体系中的语言还是其他语言都提供了一定形式的支持,比如C++(auto)、C#(var)、Scala(var/val)以及Go(通过:=进行声明)。至于该使用var作为关键字,还是使用let或类似于C/C++中的auto作为关键字,之前曾经有过一个面向开发者的调查。大约84%的回答表明定义可变内容的变量用关键字var是恰当的,只有百分之几的回答者建议使用auto更合适。根据Java语言架构师Brian Goetz介绍,该功能应该使用关键词var。
关于该特性的用法,在reddit上有一些讨论。有人表示,即便在支持“auto”语法的语言中,该特性使用的也比较少,因为有些人希望一眼就能看出变量的类型是什么。也有人认为,var有它的适用空间,在小的代码块中,直接用它实例化对象是可以的。如果是作为方法返回值的话,还是希望明确声明类型,Java的类型推断并不支持方法返回值,这一点倒不必担心。如果函数或代码块比较长的话,就不建议使用var了并要考虑适时进行代码的重写。时间和经验将会让我们更加明确应该在何时使用新功能,就像Optional刚出现时,也是耗费了一些时间才明确其推荐适用场景。
Valhalla项目中包含了一些有趣的JEP,包括值类型(Value Type)、针对原始类型实现泛型功能、增强的volatile等,外界很期待这些内容最终也能添加到新版本中。
2017慧都十四周年狂欢搞事情!砸金蛋100%抽现金红包、满额豪送iPhone X、iPhone 8、DevExpress汉化免费送、团队升级培训套包劲省10万元......更多惊喜等您来探索!

[PresentationContext(DicomUidType.VideoPhotographicImageStorage, DicomUidType.ImplicitVRLittleEndian,
DicomUidType.JPEG2000,
DicomUidType.JPEG2000LosslessOnly,
DicomUidType.JPEGBaseline1,
DicomUidType.JPEGExtended2_4,
DicomUidType.ExplicitVRBigEndian,
DicomUidType.ExplicitVRLittleEndian,
DicomUidType.JPEGLosslessNonhier14,
DicomUidType.JPEGLosslessNonhier14B,
DicomUidType.Mpeg4AvcH264BdCompatibleHighProfileLevel_4_1,
DicomUidType.Mpeg4AvcH264HighProfileLevel4_1)]
[PresentationContext(DicomUidType.VideoPhotographicImageStorage, DicomUidType.ImplicitVRLittleEndian,
DicomUidType.JPEG2000,
DicomUidType.JPEG2000LosslessOnly,
DicomUidType.JPEGBaseline1,
DicomUidType.JPEGExtended2_4,
DicomUidType.ExplicitVRBigEndian,
DicomUidType.ExplicitVRLittleEndian,
DicomUidType.JPEGLosslessNonhier14,
DicomUidType.JPEGLosslessNonhier14B,
DicomUidType.Mpeg4AvcH264BdCompatibleHighProfileLevel_4_1,
DicomUidType.Mpeg4AvcH264HighProfileLevel4_1,
DicomUidType.MPEG2MainProfileHighLevel,
DicomUidType.MPEG2MainProfileMainLevel)]
试用、下载、了解更多产品信息请点击"咨询在线客服"

Dynamotive是ABB集团的一员,是一个主要部署在汽车行业的高性能实时控制系统的高档品牌供应商。Dynamotive为主要汽车制造商及其遍布欧洲、美国和亚洲的供应商提供测试设备和工具软件。
“Dynamotive在对众多的选择进行鉴定后选择了LightningChart。没有任何一种替代方案能够做到在性能方面如此接近完美。”
——软件开发经理安德鲁·普尔(Andrew Poole)
Dynamotive使用LightningChart从控制系统实时提供数据。他们在LightningChart周围建立了一个解决方案,可以同时并且持续地以多个采样率显示和记录数据。采样率从1Hz到50 kHz不等,屏幕刷新率可以调节高达50 Hz,为用户提供了关于控制过程决策所需的信息。
当被问及LightningChart的最佳优势时,Poole先生给出答复:“LightningChart的最佳功能是性能,性能和性能。”

示例:表示运行节气门循环的图像
LightningChart给予Dynamotive的主要优点是使他们能够快速开发可靠和高性能的实时数据。“除了使用LightningChart为我们的控制系统实现高性能实时数据趋势,我们可以在两周内构建一个驱动程序辅助应用程序(使车辆的驾驶员能够遵循道路简档),早期的实施需要几个月 需要尝试并获得体面的图形性能,但与LightningChart的优异性能是给定的。”软件开发经理Poole如是介绍。
Dynamotive团队并没有真的必须使用技术支持。 安德鲁·普尔(Andrew Poole):“我们是LightningChart的早期使用者,当时有一些来自Arction创始人的电子邮件让我们犹豫了,但之后,我们需要做的大部分工作都很容易实现,这是因为拥有了直接和结构合理的API。”
观看视频,了解LightningChart如何整合到Dynamotive开发的汽车遥测软件中:
VectorDraw web library (javascript)是一个矢量图形库,它不仅能打开CAD图纸,而且能显示任何支持HTML5标准平台上的通用矢量对象,如Windows,安卓,iOS和Linux。无需任何安装,VectorDraw web library (javascript)就可以运行在任何支持canvas标签和Javascript的主流浏览器(Chrome, Firefox, Safari, Opera, Dolphin, Boat等等)中。这意味着可以用DXF,DWG,DGN,VDML等多种格式在任何台式、平板电脑,智能手机和便携式笔记本上展现出你的业务。
VectorDraw web组件是一个革新性项目,其功能和性能得到了快速的提升。这意味着 VectorDraw web library 一直在加入新的功能和发展潜力。
