Deploy an SWT application using Java Web Start

Eclipse内存配置实战:Heap与Metaspace调优指南 Java虚拟机(JVM)内存管理是保障IDE稳定运行的基础能力,其核心包括堆(Heap)和元空间(Metaspace)两大区域。Heap用于存储对象实例,受-Xms和-Xmx参数约束;Metaspace替代永久代,承载类元数据,默认无上限但需显式限制以避免系统内存耗尽。合理配置不仅提升Eclipse启动速度、热部署响应与GC效率,更能规避因类加载爆炸或静态引用泄漏引发的OutOfMemoryError。本文结合Spring Boot多模块、微服务及插件开发等典型场景,提供可验证的参数组合、MAT内存分析方法 阅读详情

http://www-128.ibm.com/developerworks/java/library/os-jws/

Level: Introductory

Jeff Gunther (jeff.gunther@intalgent.com), General Manager, Intalgent Technologies

19 Jun 2003

Over the past few months, the Standard Widget Toolkit (SWT) has continued to pick up momentum and is capturing more and more of the brain-share of Java developers. At some point in the development process of an SWT application -- typically after a basic prototype is operational -- concerns about the deployment process arise. Unlike traditional Java applications, SWT applications require some operating system-specific libraries to be loaded before an application can operate. While the ongoing deployment and maintenance of these libraries might seem like a headache, rest assured there is a solution -- Sun's Java Web Start. The marriage of SWT with Java Web Start provides powerful tools to deploy great-looking client-side Java applications.

Overview of SWT

The introduction of Standard Widget Toolkit (SWT) into the development community couldn't have come at a better time. While Sun's Java Foundation Classes (JFC) has been appeasing developers of client-side applications for several years now, many have avoided using the toolkit for a variety of reasons. For many developers and architects, the dream of being able to develop client-side Java applications that visually appear, operate, and perform like traditional native desktop applications seemed remote.

Then in the middle of 2001, the Eclipse project burst onto the development landscape. Initially the Eclipse project was perceived as only an open source Integrated Development Environment (IDE) for Java; however, the project's scope is much broader. During the development of Eclipse, the SWT toolkit was born. Similar to JFC and its cousin the Abstract Window Toolkit (AWT), the SWT toolkit provides a set of widgets to developers. However, the primary distinction between SWT and other toolkits revolves around SWT's use of an operating system's underlining GUI widgets. This approach provides Java developers a cross-platform API to implement solutions that "feel" like native desktop applications.



Back to top


Overview of Java Web Start

Without the right tools, regardless of the language, deployment and maintenance of traditional desktop applications can be a major headache for developers. Thoughts of having to touch and update every workstation when a new version of the software is released haunt even the most effective support department. To ease the distribution and maintenance requirements of Java developers, Sun Microsystems introduced Java Web Start a few years ago. This technology greatly simplifies the deployment, maintenance, and upgrading of Java applications on end-user's workstations.

Using a Web browser as the initial tool to launch an application, Java Web Start is a locally installed helper application that is included with Sun's Java Runtime Environment. Whenever a user accesses a Java Network Launching Protocol (JNLP) file, the application is automatically downloaded to the user's workstation and starts running. The whole process requires little to no interaction from the end-user and greatly simplifies the effort to distribute an application. Refer to the Resources at the end of the article for more information about Java Web Start.



Back to top


File viewer application

Before we review the implementation details of how to deploy an SWT application using Java Web Start, let's take a look at the application we're going to deploy. The application that's included with this article is an example application provided by the Eclipse project. As shown in Figure 1, the application is a simple cross-platform file viewer that allows users to browse the files and folders on their hard drive.


Figure 1. File viewer running on Windows XP
File Viewer

To demonstrate the cross-platform capabilities of SWT and Java Web Start, the included example stand-alone application has been packaged to run on both Microsoft Windows and Red Hat Linux.



Back to top


Environment requirements

The code used in this document is available for download at the end of this article. In order to fully test out the file viewer application with Java Web Start, your environment must meet the following minimum requirements (see the download links in Resources):

  • Microsoft Windows XP or Red Hat Linux 8 operating system
  • Java 2 SDK, Standard Edition 1.4 or later installed
  • Apache Ant 1.5.3 or later installed
  • Jakarta Tomcat 4.1.24 or later installed

Although attention has been given to make the Ant build script cross-platform, the file viewer application has only been tested and verified on Microsoft Windows XP and Red Hat Linux 8 operating systems. Additionally, it's assumed that Tomcat is running on your local workstation and running on port 8080. Let's get started by installing, building, and running the example application.



Back to top


Installing the file viewer application

To install the file viewer application, complete the following steps:

  1. Download the source code package via the link in Resources.
  2. Unzip the fileviewer.zip file into a temporary directory.



Back to top


Security and code signing

Unlike AWT or JFC, SWT is tightly integrated with the operating system's native windowing environment. SWT uses a system library to manage the integration between its platform-independent API and the underlying operating system. By default, an application running under Java Web Start runs within a restricted sandbox. This environment controls access to resources such as the workstation's file system, system libraries, and other resources. Since SWT needs to operate outside the default sandbox to load a system library, all JAR files deployed with Java Web Start must be digitally signed. Since this application is not going to be deployed to a wide user base, we'll create a self-signed test certificate.

If you're going to put an SWT application into production, it's highly recommended that you obtain a certificate from a certificate authority like Thawte or VeriSign.



Back to top


Creating a self-signed certificate

To create a self-signed test certificate, complete the following steps:

  1. Execute the following command within the directory where you unpacked the source code: keytool -genkey -keystore keystore -alias myself.

    You'll be prompted to provide details about the new key including a password, your name, locality, etc. In order to use the provided Ant build process, make sure you set the password to "password". If you don't want to use the hard-coded password of "password", edit the "sign-jars" target within the build.xml file. The actual process of signing each JAR file is completed during the Ant build.

  2. To verify that the keystore was properly created, execute the following command within the directory where you unpacked the source code: keytool -list-keystore keystore

    The output will appear something like the following:

    
    Keystore type: jks
    Keystore provider: SUN
           
    Your keystore contains 1 entry
           
    myself, Jun 3, 2003, keyEntry,
    Certificate fingerprint (MD5):B8:C4:48:ED:68:E8:FE:47:83:78:F5:14:4E:28:5C:80



Back to top


Building the file viewer application

To build the file viewer application, complete the following steps:

  1. To clean the environment, execute the following command within the directory where you unpacked the source code: ant clean
  2. Execute the following command to start the build process: ant

If your environment met the requirements and was properly configured, you should have seen something similar to the following:


Buildfile: build.xml

init:

compile-common:

compile-module:
     [echo] Compiling ...

package-common:

package-swtlib:

sign-jars:
     [echo] Signing JARS...
  [signjar] Signing Jar : D:/FileViewer/dist/swt-lib.jar
  [signjar] Signing Jar : D:/FileViewer/dist/fileviewer.jar
     [copy] Copying 1 file to D:/FileViewer/dist
  [signjar] Signing Jar : D:/FileViewer/dist/swt-win32.jar

package-web:
      [war] Building war: D:/FileViewer/dist/fileviewer.war

default:

BUILD SUCCESSFUL
Total time: 6 seconds



Back to top


Running the file viewer application

Before using Java Web Start to deploy the file viewer application, let's try executing the application locally. To start the application, execute the following command within the directory where you unpacked the source code: ant run

Upon execution of the Ant script, the file viewer application should appear. Figure 2 demonstrates the application running under Red Hat Linux 8.


Figure 2. File viewer running on Red Hat Linux 8
File viewer on Red Hat 8


Back to top


Deploying and testing the file viewer application

To deploy the application to Tomcat 4, complete the following steps:

  1. Copy the fileviewer.war file from the dist directory to the webapps directory under Tomcat 4.
  2. Execute the script to start Tomcat 4.
  3. Open your Web browser to the following URL and click on the "Launch Application" link: http://localhost:8080/fileviewer/index.html

    Upon clicking the link, you should see the following image (Figure 3) while the application's JAR files will be downloaded to the workstation:


    Figure 3. File viewer
    File viewer
  4. The first time the application is downloaded, you'll see the following dialog box, shown in Figure 4.
    Figure 4. Security warning
    Security warning

    Click "Start" to start the file viewer application.



Back to top


Implementing a JNLP File

Now that we've covered how to build, distribute, and deploy an SWT application using Sun's Java Web Start, let's review how to implement a JNLP file. The Java Network Launching Protocol specification is managed via the Java Community Process (JCP). Since this article's purpose is to cover the specifics of deploying an SWT application using this technology, not much background information is provided. For more information and background about Java Web Start, refer to Steve Kim's article, "Java Web Start", listed in the Resources.

Listing 1 illustrates the various tags used within a JNLP file for an SWT application.


Listing 1. index.jnlp file


1    <?xmlversion="1.0" encoding="utf-8"?>
2       <jnlp spec="1.0+"codebase="http://localhost:8080/fileviewer"href="index.jnlp">
3           <information>
4                   <title>File Viewer</title>
5                   <vendor>IBM developerWorks</vendor>
6                   <homepage href="index.html"/>
7                   <description>File Viewer</description>
8                   <description kind="short">FileViewer</description>
9           </information>
10          <security>
11                   <all-permissions/>
12           </security>
13           <resources>
14                   <j2se version="1.4"/>
15                   <jar href="fileviewer.jar"/>
16                   <nativelib href="swt-lib.jar"/>
17           </resources>
18           <resources os="Windows"> 
19                   <jar href="swt-win32.jar"/>
20           </resources>
21           <resources os="Linux"> 
22                   <jar href="swt-linux.jar"/>
23           </resources>
24           <application-descmain-class="org.eclipse.swt.examples.fileviewer.FileViewer"/>
25   </jnlp>

Let's step through the important parts of this XML file:

  1. Because an SWT application is required to load a system library upon execution, it needs to have full access to the user's workstation. Lines 10 through 12 show how an application can request full access to a client's environment. In order for Java Web Start to grant this level of access, all the application's JAR files must be digitally signed.
  2. As shown on line 16, we need to declare a nativelib tag to tell Java Web Start that this JAR file contains native libraries. In our example file viewer application, this JAR file contains a Windows DLL and a series of SO files for Linux.
  3. Lines 18 through 23 load the appropriate SWT JAR for each operating system. The "resources" tag allows you to protect resources for use only by a particular operating system and architecture. The os attribute specifies the operating system for which the resources element should be considered. This value is based on the end-user's os.name Java system property. While not used in this example, you can also use an arch attribute to further restrict access to a Java library. The arch attribute is based on the end-user's os.arch Java system property.

For more information about the various elements and format of a JNLP file, refer to the Resources below.



Back to top


Summary

The coupling of the SWT user interface toolkit and Java Web Start provides developers with a great set of tools to deploy create highly interactive client-side Java applications. The example file viewer application provides a build and packaging framework that you can use to create your own stand-alone SWT applications to distribute via Java Web Start.




Back to top


Download

NameSize Download method
os-jws/fileviewer.zip FTP
Information about download methodsGet Adobe® Reader®


Back to top


Resources

  • Download the companion source code that was demonstrated throughout this article.

  • Download Java 2 SDK, Standard Edition 1.4.1 from Sun Microsystems.

  • Download Ant 1.5.3 from the Apache Software Foundation.

  • Download Tomcat 4.1.24 from the Jakarta project.

  • For an overview of Java Web Start and information on developing and distributing Java applications for the client side, read Steve Kim's "Java Web Start" (developerworks, September 2001).

  • More information about Java Network Launching Protocol and API specification and the reference implementation is available at Sun's Web site.

  • The Eclipse project provides the SWT toolkit that was used in this article's source code.

  • The Eclipse Technical Overview provides an introduction to the core components of the Eclipse platform.

  • The Eclipse project has released a series SWT examples that provide a good starting point for learning more about creating stand-alone SWT applications.



Back to top


About the author

Jeff Gunther, a Studio B author, is the General Manager and founder of Intalgent Technologies, an emerging provider of software products and solutions utilizing the Java 2 Enterprise Edition and Lotus Notes/Domino platforms. Jeff has been a part of the Internet industry since its early, "pre-Mosaic" days. He has professional experience in all aspects of the software life cycle including specific software development expertise with Java/J2EE, DHTML, XML/XSLT, database design, and handheld devices. You can contact him at jeff.gunther@intalgent.com.

SWT入门 Swt使用步骤: 首先下载SWT的jar包,或者从Eclipse中导入。(org.eclipse.swt.win32.win32.x86_64_3.104.2.v20160212-1350.jar) SWT中最基本的两个类是Display和Shell类。 Display一般只需创建一个即可,它继承Device类,负责操作系统和SWT建立交互。 Display也封装了本地系统的资源,控件和事件 阅读详情

相关推荐

ArcGIS中如何计算多个点到特定线的最短距离

现有一个点图层和一个面图层,怎么来计算这些点到这个面图层,两个面的公共边的最短直线距离呢? 1.首先得将两个图层都转为 投影坐标系 打开工具箱-数据管理工具-要素-面转线 ​ ​ 2.将面图层设为输入要素 注意要将“识别和存储面邻域信息”勾选 ​ 3.面转线成功后 打开线属性表,线图层拥有了 LEFT_FID和RIGHT_FID两个字段 ​ 4.按属性选择,表达式中输入 “LEFT_FID”<>-1 即可选出两个面的公共边 ​再将选...

GIS蒲公英的博客 6715

一个SWT Application如何转职成为RCP Appliactioin

(注:以下观点未经证实,请自行斟酌使用)一个旧的SWT应用,应该都是有一个main函数里初始化一些UI组件,然后run一个事件循环在RCP中,由于是基于Eclipse的插件体系,也就是说,使用我前面那篇文章发布的RCP Application,是可以直接发布成Eclipse插件的所以,对于UI组件的控制也要遵循Eclipse的插件体系的代码要求,看看Hello RCP模板中的几个类:App

好好学习,天天向上! 1253

ubuntu18.04安装gtsam过程及报错error: invalid initialization of reference of type ‘const std::vector<bool>&’

这里建议从这个链接下,不要从官网下,可能会有版本冲突 2.安装依赖 3.编译 报错: 1. error: invalid initialization of reference of type ‘const std::vector&’ from expression of type ‘const std::vector’ 124 | const std::vector& mask() const { retur...

qq_35102059的博客 2912

使用swt的Application Window时怎么删除右上角的最大化和最小化以及关闭图标

问题:今天在使用swt中的Application Window时,想删除右上角的最大化最小化以及关闭图标,最开始如下图:将红圈部分的图标删除,得到如下图:解决方法:在源代码中写入SWT.NONE即可,例:...

HJBZF的博客 1324

FPGA_adc采样并通过以太网发送到上位机

本项目使用FPGA-ZYNQ-7020采集8通道ADC数据,通过以太网上传到上位机显示波形PL部分包括数据的获取与处理,数据从PL传递到PSPS部分包括以太网的发送,由PL到PS的中断触发本文章不详细讲解背后原理 但保证每一步足够详细,跟着就能实现。本人FPGA平台 大磊FPGA7020开发板 vivado2020.2 vitis2020.2 匿名上位机公开版

weixin_42304868的博客 5626

AXI Timer IP核使用说明

AXI Timer是提供定时技术功能的集成IP核,具有时间生成、事件捕获、产生PWM波以及产生中断的功能,下面具体讲述Timer IP核的使用说明。

weixin_43418104的博客 2489

关于SWT常用组件(按钮,复选框,单选框(Button类))

Button是SWT中最常用的组件.Button类的继承关系图:   Button类的构造方法是newe Button(Composite parent,int style)它有两个参数: 第一个参数:是Button创建在哪个容器上.Composite是最常用的容器,而Shell是 Composite的子类.所以此参数也能接受Shell和任何继承自Composite的子类. 第二个参数用...

weixin_34247032的博客 466

4G LTE 与 5G 无线网络规划对比:从 BBU/RRU 到 CU/DU/AAU 的架构演进解析

本文深度解析4G LTE与5G无线网络架构的演进差异,从BBU/RRU分立式架构到CU/DU/AAU三级重构,揭示移动通信代际跃迁的技术本质。重点对比了网络规划中的覆盖能力、容量规划、传输网络等九大维度,为通信工程师提供实用的技术对照手册,助力5G网络高效部署。

weixin_32821533的博客 289

在eclipse中开发SWT客户端程序

作者:SummerChill  出处:http://www.cnblogs.com/DreamDrive/  在Eclispe中开发SWT程序的步骤: 1.在eclipse中"文件"---->"新建"----->"其他"----输入"swt" 选择SWT/JFace Java Project  然后输入项目名字和包的名字(走默认配置就可以了) 比如建立的想项

sinat_15433607的专栏 5730

OpenStack 2018 年终盘点

目录 文章目录目录前言OpenStack 一年来的成长NovaCinderNeutronIronicCyborgOctaviaKollaMagnumZunKuryr从 OpenStack 到 OpenInfra 前言 这是最好的时代,也是最坏的时代 — — 查尔斯·约翰·赫芬姆·狄更斯《双城记》 年关将至,闲暇之余,回顾我与 OpenStack 的 2018。 NOTE:仅作为个人见解,与公...

烟云的计算 3596

在 PFCG 中完成 SAP Fiori 对象分配:把 Business Catalog、Space、Page 与授权一次讲透

摘要:SAP Fiori权限配置的关键在于理解Business Catalog与Space的分层授权逻辑。传统SAP GUI中直接分配事务码的方式不适用于Fiori环境,必须通过PFCG为角色分配Catalog(提供应用访问权限)和Space(控制首页展示结构)。Catalog会自动解析所需OData服务授权,而Space则决定用户在Launchpad中看到的导航布局。常见错误包括直接分配Page而非其所属Space,或仅配置Space而忽略Catalog。最佳实践是优先使用Catalog驱动授权提议,再在

2007 年 ~ 2025 年,深耕 SAP 技术 18 年 327

SWT/Jface ApplicationWindow

简单写了一个如何添加菜单栏的ApplicationWindow。 网上这方面的信息很少。 悲剧 import org.eclipse.jface.action.MenuManager; import org.eclipse.jface.action.ToolBarManager; import org.eclipse.jface.window.ApplicationWindow; im

Hello Eclipse Plugin 黑夜 2303

开源鸿蒙具身机器人(ROS2框架):从内核驱动到智能算法的完整实践

本指导文档旨在为开发者提供完整的开源鸿蒙(OpenHarmony)具身机器人开发解决方案,涵盖从底层驱动到上层ROS2应用的全栈开发流程。文档结合OpenHarmony内核驱动移植技术和ROS2机器人操作系统,为具身机器人开发提供详细的技术指导。具身机器人(Embodied Robot)是指具有物理实体、能够感知环境并与之交互的智能机器人系统。感知-决策-执行闭环多模态传感器融合(视觉、听觉、触觉、力觉)实时环境感知与理解智能决策与规划精确运动控制执行具身智能特性物理世界交互能力。

m0_67505153的博客 1271

JAVA SWT table界面+数据(多图)

界面 1.布局 选用两个composite, 设置shell的Layout为FillLayout; 设置Layout-Type(布局类型)为垂直分布; 设置右滑块,下滑块; 2.添加table组件 上面的composite添加的是CheckboxTableViewer,下面的是普通的Table; 同样需要设置两个composite的Layout属性为Fill...

华容道的博客 1万+

假人有限元模型

假人模型,车辆碰撞假人有限元模型,适合做乘员安全的研究者利用

SAP B1中文培訓教材_SDK

公司内部培训资料,对开发工具 ,DIAPI, UIAPI,Add-ON有详细解说

SWT开发Java应用程序GUI入门

第一次做了Java GUI,我选择用elipse自己的前段开发工具 SWT/JFace。这篇文章是基于eclipse MARS.2.  用SWT编写的GUI的风格如下:                                                                       1、 SWT中的一些概念1.1 Display & Shell Display 和 She

王以山的专栏 3万+

文档:亲测可用解决vnc灰屏,黑屏,鼠标大黑叉情况

主要解决vnc-viewer灰屏,黑屏,鼠标大黑叉等现象,详细见文档。

Swt的桌面程序Application window 的打包发布

                               客户端打包由于我们的客户端是在Eclipse下开发的,所以我们可以使用Eclipse丰富的插件来实现迅速快捷的程序打包。Fatjar就是一款专门为桌面程序打包设计的Eclipse插件,它可以将主程序中使用的所有引用类都封装到一个jar包中。它的下载地址: http://fjep.sourceforge.net/ 我下载到的是

龙的天空 1583

STM32F407中文手册

STM32f407中文手册 本参考手册面向应用开发人员,提供有关使用 STM32F405xx/07xx、STM32F415xx/17xx、 STM32F42xxx 和 STM32F43xxx 微控制器存储器与外设的完整信息。STM32F405xx/07xx、STM32F415xx/17xx、STM32F42xxx 和 STM32F43xxx 构成一个微 控制器系列,各产品具有不同的存储器大小、封装和外设。有关订购信息以及器件的机械与电气特性,请参见数据手册。有关 ARM Cortex™-M4F 内核的信息,请参见《Cortex™-M4F 技术参考手册》。

java常用控件_Swt常用控件中文教程(转)

(样图没有贴上,不好意思)1、Eclipse中swt的配置建议配置:jdk1.4.2以及eclipse3.1在代码中调用swt控件之前,首先建立一个项目,然后选择该项目的properties -> Java Build Path,将standard Widget ToolKit加入到Library页当中。如下图所示:接下来可以建立第一个eclipse小程序,新建一个class,并且在该cla...

weixin_42106357的博客 1447

SWT中的模式和非模式窗体(modal or non-modal)

modal or non-modal

张德中的专栏 5171

java swt_JAVA从入门到精通:SWT(JFace)体验之ApplicationWindow

本文主要向大家介绍了JAVA从入门到精通的SWT(JFace)体验之ApplicationWindow,通过具体的代码向大家展示,希望对大家学习JAVA从入门到精通有所帮助。测试代码如下:复制代码代码如下:packageswt_jface.demo;importorg.eclipse.jface.window.ApplicationWindow;importorg.eclipse.swt.S...

weixin_34030345的博客 507

SWT/JFace开发入门指南

写在前面的话终于决定提起笔来写一篇关于swt和JFace编程的文章。在开始之前,我想先介绍一下你能够从将要出现的这一系列文章里得到什么,以及更重要的,你不能得到什么。我们的时间是如此之重要,以至于我们很难容忍把它浪费在自己不关心的事情上。因为我刚开始写,所以到底这些文章会分成几次发布出来,也很难讲。但是我心里大体有这样一个提纲。也就是说,我打算介绍以下方面的内容:l         设

回到未来。。。 3614

一个简单的SWT程序实例及详解

本文译自《 Eclipse.Building.Commercial.Quality.Plug.ins.2nd.Edition 》第四章第二节,详细解释了 SWT 程序的语句,希望对入门者有所帮助。 让我们从简单的 HelloWorld 应用程序开始。  一、将SWT添加到工程的类路径中 首先建立一个java工程。在开始使用SWT之前,需要将SWT库文件添加到工程的类路径中。步骤

cpenet的专栏 3896

SWT -- ApplicationWindow

java语言的GUI包,个人比较喜欢SWT/Jface。 几年前用swing编写了 一套软件,在windows 上lookAndFeel的确不尽人意。 纯粹使用SWT,编码比较繁琐和杂乱。 因此可以适当的采用jface来优化, 主窗口 主窗口可以继承Jface的ApplicationWindow,比如: public class MainGui extends Applic...

iteye_5335的博客 348

SWT/JFACE

Using JFace outside the Eclipse platformJFace can be used in standalone SWT+JFaceapps, without requiring the Eclipse Runtime or other parts of theEclipse Platform. This was made easier to do in

jisuanji8509的专栏 1819

SWT中shell的各种style介绍

这是以前自己看SWT的文档总结的笔记,对于各种shell的介绍.粘过来充充数先.   BORDER——当只有BORDER的时候,窗口是一个只有细细白色边框的空白窗口,没有title那一圈蓝色的边框,也没有最大化,最小化,关闭。不能resize,不能移动。在任务栏里右键没有反应。   CLOSE——当只有CLOSE的时候,窗口会出现蓝色的边框,并且有title,title上显示的是setTe...

火拳 582
上一篇: 怎样用Java实现MSN Messager的功能
下一篇: CC(标准)版D碟收藏指南(前言)
foxcai
博客等级 码龄24年 64粉丝 51原创
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

个

红包个数最小为10个

元

红包金额最低5元

当前余额3.43元 前往充值 >
需支付:10.00元
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付元
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值