Sunil Patil 告诉你如何扩展Struts

【AI方案集】个人记忆库型AI智能体终身伴侣方案.docx 这套AI技术方案不走“先堆概念再硬套场景”的老路,而是以业务痛点为锚点,把机器视觉识别、预测性分析、大模型知识赋能等能力拆解成轻量化可落地的功能模块,直接嵌入生产运营的关键环节,既能快速落地见效,又能通过持续的数据迭代逐步放大价值,帮企业在不盲目新增硬件投入的前提下,稳步完成智能化升级,实实在在把AI变成能降本、提效、控风险的生产工具。 立即下载

 by Sunil Patil
11/10/2004

Introduction

I have seen lot of projects where the developers implemented a proprietary MVC framework, not because they wanted to do something fundamentally different from Struts, but because they were not aware of how to extend Struts. You can get total control by developing your own MVC framework, but it also means you have to commit a lot of resources to it, something that may not be possible in projects with tight schedules.

Struts is not only a very powerful framework, but also very extensible. You can extend Struts in three ways.

  1. PlugIn: Create your own PlugIn class if you want to execute some business logic at application startup or shutdown.
  2. RequestProcessor: Create your own RequestProcessor if you want to execute some business logic at a particular point during the request-processing phase. For example, you might extend RequestProcessor to check that the user is logged in and he has one of the roles to execute a particular action before executing every request.
  3. ActionServlet: You can extend the ActionServlet class if you want to execute your business logic at either application startup or shutdown, or during request processing. But you should use it only in cases where neither PlugIn nor RequestProcessor is able to fulfill your requirement.

In this article, we will use a sample Struts application to demonstrate how to extend Struts using each of these three approaches. Downloadable sample code for each is available below in the Resources section at the end of this article. Two of the most successful examples of Struts extensions are the Struts Validation framework and the Tiles framework.

I assume that you are already familiar with the Struts framework and know how to create simple applications using it. Please see the Resources section if you want to know more about Struts.

PlugIn

According to the Struts documentation "A plugin is a configuration wrapper for a module-specific resource or service that needs to be notified about application startup and shutdown events." What this means is that you can create a class implementing the PlugIn interface to do something at application startup or shutdown.

Say I am creating a web application where I am using Hibernate as the persistence mechanism, and I want to initialize Hibernate as soon as the application starts up, so that by the time my web application receives the first request, Hibernate is already configured and ready to use. We also want to close down Hibernate when the application is shutting down. We can implement this requirement with a Hibernate PlugIn by following two simple steps.

  1. Create a class implementing the PlugIn interface, like this:

2.            

3.           public class HibernatePlugIn implements PlugIn{

4.                   private String configFile;

5.                   // This method will be called at application shutdown time

6.                   public void destroy() {

7.                          System.out.println("Entering HibernatePlugIn.destroy()");

8.                          //Put hibernate cleanup code here

9.                          System.out.println("Exiting HibernatePlugIn.destroy()");

10.               }

11.               //This method will be called at application startup time

12.               public void init(ActionServlet actionServlet, ModuleConfig config)

13.                      throws ServletException {

14.                      System.out.println("Entering HibernatePlugIn.init()");

15.                      System.out.println("Value of init parameter " +

16.                                          getConfigFile());

17.                      System.out.println("Exiting HibernatePlugIn.init()");

18.               }

19.               public String getConfigFile() {

20.                      return name;

21.               }

22.               public void setConfigFile(String string) {

23.                      configFile = string;

24.               }

25.       }

The class implementing PlugIn interface must implement two methods: init() and destroy(). init() is called when the application starts up, and destroy() is called at shutdown. Struts allows you to pass init parameters to your PlugIn class. For passing parameters, you have to create JavaBean-type setter methods in your PlugIn class for every parameter. In our HibernatePlugIn class, I wanted to pass the name of the configFile instead of hard-coding it in the application.

  1. Inform Struts about the new PlugIn by adding these lines to struts-config.xml:

27.        

28.       <struts-config>

29.               ...

30.               <!-- Message Resources -->

31.               <message-resources parameter=

32.                 "sample1.resources.ApplicationResources"/>

33.        

34.               <!-- Declare your plugins -->

35.               <plug-in className="com.sample.util.HibernatePlugIn">

36.                      <set-property property="configFile"

37.                         value="/hibernate.cfg.xml"/>

38.               </plug-in>

39.       </struts-config>

The className attribute is the fully qualified name of the class implementing the PlugIn interface. Add a <set-property> element for every initialization parameter which you want to pass to your PlugIn class. In our example, I wanted to pass the name of the config file, so I added the <set-property> element with the value of config file path.

Both the Tiles and Validator frameworks use PlugIns for initialization by reading configuration files. Two more things which you can do in your PlugIn class are:

  • If your application depends on some configuration files, then you can check their availability in the PlugIn class and throw a ServletException if the configuration file is not available. This will result in ActionServlet becoming unavailable.
  • The PlugIn interface's init() method is your last chance if you want to change something in ModuleConfig, which is a collection of static configuration information that describes a Struts-based module. Struts will freeze ModuleConfig once all PlugIns are processed.

How a Request is Processed

ActionServlet is the only servlet in Struts framework, and is responsible for handling all of the requests. Whenever it receives a request, it first tries to find a sub-application for the current request. Once a sub-application is found, it creates a RequestProcessor object for that sub-application and calls its process() method by passing it HttpServletRequest and HttpServletResponse objects.

The RequestProcessor.process() is where most of the request processing takes place. The process() method is implemented using the Template Method design pattern, in which there is a separate method for performing each step of request processing, and all of those methods are called in sequence from the process() method. For example, there are separate methods for finding the ActionForm class associated with the current request, and checking if the current user has one of the required roles to execute action mapping. This gives us tremendous flexibility. The RequestProcessor class in the Struts distribution provides a default implementation for each of the request-processing steps. That means you can override only the methods that interest you, and use default implementations for rest of the methods. For example, by default Struts calls request.isUserInRole() to find out if the user has one of the roles required to execute the current ActionMapping, but if you want to query a database for this, then then all you have to do is override the processRoles() method and return true or false, based whether the user has the required role or not.

First we will see how the process() method is implemented by default, and then I will explain what each method in the default RequestProcessor class does, so that you can decide what parts of request processing you want to change.

 

    public void process(HttpServletRequest request,

                        HttpServletResponse response)

    throws IOException, ServletException {

        // Wrap multipart requests with a special wrapper

        request = processMultipart(request);

        // Identify the path component we will

        // use to select a mapping

        String path = processPath(request, response);

        if (path == null) {

            return;

        }

        if (log.isDebugEnabled()) {

            log.debug("Processing a '" + request.getMethod() +

                      "' for path '" + path + "'");

        }

        // Select a Locale for the current user if requested

        processLocale(request, response);

        // Set the content type and no-caching headers

        // if requested

        processContent(request, response);

        processNoCache(request, response);

        // General purpose preprocessing hook

        if (!processPreprocess(request, response)) {

            return;

       }

        // Identify the mapping for this request

        ActionMapping mapping =

            processMapping(request, response, path);

        if (mapping == null) {

            return;

        }

        // Check for any role required to perform this action

        if (!processRoles(request, response, mapping)) {

            return;

        }

        // Process any ActionForm bean related to this request

        ActionForm form =

            processActionForm(request, response, mapping);

        processPopulate(request, response, form, mapping);

        if (!processValidate(request, response, form, mapping)) {

            return;

        }

        // Process a forward or include specified by this mapping

        if (!processForward(request, response, mapping)) {

            return;

        }

        if (!processInclude(request, response, mapping)) {

            return;

        }

        // Create or acquire the Action instance to

        // process this request

        Action action =

            processActionCreate(request, response, mapping);

        if (action == null) {

            return;

        }

        // Call the Action instance itself

        ActionForward forward =

            processActionPerform(request, response,

                                action, form, mapping);

        // Process the returned ActionForward instance

        processForwardConfig(request, response, forward);

    }

  1. processMultipart(): In this method, Struts will read the request to find out if its contentType is multipart/form-data. If so, it will parse it and wrap it in a wrapper implementing HttpServletRequest. When you are creating an HTML FORM for posting data, the contentType of the request is application/x-www-form-urlencoded by default. But if your form is using FILE-type input to allow the user to upload files, then you have to change the contentType of the form to multipart/form-data. But by doing that, you can no longer read form values submitted by user via the getParameter() method of HttpServletRequest; you have to read the request as an InputStream and parse it to get the values.
  2. processPath(): In this method, Struts will read request URI to determine the path element that should be used for getting the ActionMapping element.
  3. processLocale(): In this method, Struts will get the Locale for the current request and, if configured, it will save it in HttpSession as the value of the org.apache.struts.action.LOCALE attribute. HttpSession would be created as a side effect of this method. If you don't want that to happen, then you can set the locale property to false in ControllerConfig by adding these lines to your struts-config.xml file:

4.           <controller>

5.                   <set-property  property="locale" value="false"/>

6.           </controller>

  1. processContent(): Sets the contentType for the response by calling response.setContentType(). This method first tries to get the contentType as configured in struts-config.xml. It will use text/html by default. To override that, use the following:

8.           <controller>

9.                   <set-property  property="contentType" value="text/plain"/>

10.       </controller>

  1. processNoCache(): Struts will set the following three headers for every response, if configured for no-cache:

12.        

13.       requested in struts config.xml

14.       response.setHeader("Pragma", "No-cache");

15.       response.setHeader("Cache-Control", "no-cache");

16.       response.setDateHeader("Expires", 1);

If you want to set the no-cache header, add these lines to struts-config.xml:

 

<controller>

  <set-property  property="noCache" value="true"/>

</controller>

  1. processPreprocess(): This is a general purpose, pre-processing hook that can be overridden by subclasses. Its implementation in RequestProcessor does nothing and always returns true. Returning false from this method will abort request processing.
  2. processMapping(): This will use path information to get an ActionMapping object. The ActionMapping object represents the <action> element in your struts-config.xml file.

19.        

20.       <action path="/newcontact" type="com.sample.NewContactAction"

21.               name="newContactForm" scope="request">

22.               <forward name="sucess" path="/sucessPage.do"/>

23.               <forward name="failure" path="/failurePage.do"/>

24.       </action>

The ActionMapping element contains information like the name of the Action class and ActionForm used in processing this request. It also has information about ActionForwards configured for the current ActionMapping.

  1. processRoles(): Struts web application security just provides an authorization scheme. What that means is once user is logged into the container, Struts' processRoles() method can check if he has one of the required roles for executing a given ActionMapping by calling request.isUserInRole().

26.        

27.               <action path="/addUser" roles="administrator"/>

Say you have AddUserAction and you want only the administrator to be able to add a new user. What you can do is to add a role attribute with the value administrator in your AddUserAction action element. So before executing AddUserAction, it will always make sure that the user has the administrator role.

  1. processActionForm(): Every ActionMapping has a ActionForm class associated with it. When Struts is processing an ActionMapping, it will find the name of the associated ActionForm class from the value of the name attribute in the <action> element.

29.       <form-bean name="newContactForm"

30.                  type="org.apache.struts.action.DynaActionForm">

31.                      <form-property name="firstName"

32.                                 type="java.lang.String"/>

33.                      <form-property name="lastName"

34.                                 type="java.lang.String"/>

35.       </form-bean>

In our example, it will first check to see if an object of the org.apache.struts.action.DynaActionForm class is present in request scope. If so, it will use it; otherwise, it will create a new object and set it in the request scope.

  1. processPopulate(): In this method, Struts will populate the ActionForm class instance variables with values of matching request parameters.
  2. processValidate(): Struts will call the validate() method of your ActionForm class. If you return ActionErrors from the validate() method, it will redirect the user to the page indicated by the input attribute of the <action>element.
  3. processForward() and processInclude(): In these functions, Struts will check the value of the forward or include attributes of the <action> element and, if found, put the forward or include request in the configured page.

39.        

40.               <action forward="/Login.jsp" path="/loginInput"/>

41.               <action include="/Login.jsp" path="/loginInput"/>

You can guess difference in these functions from their names. processForward() ends up calling RequestDispatcher.forward(), and processInclude() calls RequestDispatcher.include(). If you configure both forward and include attributes, it will always call forward, as it is processed first.

  1. processActionCreate(): This function gets the name of the Action class from the type attribute of the <action> element and create and return instances of it. In our case it will create an instance of the com.sample.NewContactAction class.
  2. processActionPerform(): This function calls the execute() method of your Action class, which is where you should write your business logic.
  3. processForwardConfig(): The execute()method of your Action class will return an object of type ActionForward, indicating which page should be displayed to the user. So Struts will create RequestDispatcher for that page and call the RequestDispatcher.forward() method.

The above list explains what the default implementation of RequestProcessor does at every stage of request processing and the sequence in which various steps are executed. As you can see, RequestProcessor is very flexible and it allows you to configure it by setting properties in the <controller> element. For example, if your application is going to generate XML content instead of HTML, then you can inform Struts about this by setting a property of the controller element.

Creating Your own RequestProcessor

Above, we saw how the default implementation of RequestProcessor works. Now we will present a example of how to customize it by creating our own custom RequestProcessor. To demonstrate creating a custom RequestProcessor, we will change our sample application to implement these two business requirements:

  • We want to create a ContactImageAction class that will generate images instead of a regular HTML page.
  • Before processing every request, we want to check that user is logged in by checking for userName attribute of the session. If that attribute is not found, we will redirect the user to the login page.

We will change our sample application in two steps to implement these business requirements.

  1. Create your own CustomRequestProcessor class, which will extend the RequestProcessor class, like this:

2.           public class CustomRequestProcessor

3.               extends RequestProcessor {

4.                   protected boolean processPreprocess (

5.                       HttpServletRequest request,

6.                       HttpServletResponse response) {

7.                       HttpSession session = request.getSession(false);

8.                   //If user is trying to access login page

9.                   // then don't check

10.               if( request.getServletPath().equals("/loginInput.do")

11.                   || request.getServletPath().equals("/login.do") )

12.                   return true;

13.               //Check if userName attribute is there is session.

14.               //If so, it means user has allready logged in

15.               if( session != null &&

16.               session.getAttribute("userName") != null)

17.                   return true;

18.               else{

19.                   try{

20.                       //If no redirect user to login Page

21.                       request.getRequestDispatcher

22.                           ("/Login.jsp").forward(request,response);

23.                   }catch(Exception ex){

24.                   }

25.               }

26.               return false;

27.           }

28.        

29.           protected void processContent(HttpServletRequest request,

30.                       HttpServletResponse response) {

31.                   //Check if user is requesting ContactImageAction

32.                   // if yes then set image/gif as content type

33.                   if( request.getServletPath().equals("/contactimage.do")){

34.                       response.setContentType("image/gif");

35.                       return;

36.                   }

37.               super.processContent(request, response);

38.           }

39.       }

In the processPreprocess method of our CustomRequestProcessor class, we are checking for the userName attribute of the session and if it's not found, redirect the user to the login page.

For our requirement of generating images as output from the ContactImageAction class, we have to override the processContent method and first check if the request is for the /contactimage path. If so, we set the contentType to image/gif; otherwise, it's text/html.

  1. Add these lines to your struts-config.xml file after the <action-mapping> element to inform Struts that CustomRequestProcessor should be used as the RequestProcessor class:

41.       <controller>

42.               <set-property  property="processorClass"

43.               value="com.sample.util.CustomRequestProcessor"/>

44.       </controller>

Please note that overriding processContent() is OK if you have very few Action classes where you want to generate output whose contentType is something other than text/html. If that is not the case, you should create a Struts sub-application for handling requests for image-generating Actions and set image/gif as the contentType for it.

The Tiles framework uses its own RequestProcessor for decorating output generated by Struts.

ActionServlet

If you look into the web.xml file of your Struts web application, it looks like this:

 

<web-app >

        <servlet>

            <servlet-name>action=</servlet-name>

            <servlet-class>org.apache.struts.action.ActionServlet</servlet-class>

            <!-- All your init-params go here-->

        </servlet>

        <servlet-mapping>

            <servlet-name>action</servlet-name>

            <url-pattern>*.do</url-pattern>

        </servlet-mapping>

</web-app >

That means ActionServlet is responsible for handling all of your requests to Struts. You can create a sub-class of the ActionServlet class if you want to do something at application startup or shutdown or on every request, but you should try creating a PlugIn or RequestProcessor before extending the ActionServlet class. Before Servlet 1.1, the Tiles framework was based on extending the ActionServlet class to decorate a generated response. But from 1.1 on, it's used the TilesRequestProcessor class.

Conclusion

Deciding to develop your own MVC framework is a very big decision--you should think about the time and resources it will take to develop and maintain that code. Struts is a very powerful and stable framework and you can change it to accommodate most of your business requirements.

On the other hand, the decision to extend Struts should not be taken lightly. If you put some low-performance code in your RequestProcessor class, it will execute on every request and can reduce the performance of your whole application. And there will be situations where it will better for you to create your own MVC framework than extend Struts.

Resources

Sunil Patil has worked on J2EE technologies for four years. He is currently working with IBM Software Labs.

 

【能源系统优化】基于MATLAB的光储充一体化多目标调度:光伏自用率与充电成本权衡及储能联合调控 MATLAB 光储充一体化运行优化|光伏自用率与充电成本权衡 内容概要:本文围绕MATLAB实现的光储充一体化系统运行优化展开,旨在通过建立统一的能量调度模型,量化光伏自用率与充电成本之间的权衡关系,提升设备利用效率与运行安全性,并形成可复现的工程分析能力。项目采用多目标混合整数线性规划方法,综合考虑分时电价、储能损耗、光伏消纳与车辆充电需求,在满足功率平衡、储能状态递推、充放电互斥等约束条件下,实现经济性与环保性的协同优化。通过归一化加权目标函数,支持灵活调整运营策略偏好,并利用MATLAB R2025b完成从数据生成、建模求解到结果可视化的完整流程。配套GUI界面支持参数配置、模型训练、结果预测与运行监控,增强了系统的实用性与交互性。 适合人群:具备一定MATLAB编程基础,从事新能源系统规划、电动汽车充电站运营、微电网控制或综合能源管理的技术人员与研究人员,尤其适合工作年限1-3年、希望深入掌握能源系统优化建模与工程实现的研发人员。 使用场景及目标:①优化城市公共充电站、工业园区、高速服务区等场景的光储充协同运行,降低运营成本并提高光伏利用率;②支持日前调度与滚动优化,实现从静态分析到动态调控的升级;③为储能配置、容量规划、需求响应申报及投资回报评估提供量化决策工具;④通过GUI界面实现数据驱动的模型训练与预测,辅助制定最优充放电策略。 阅读建议:此资源以MATLAB为开发平台,强调从理论建模到工程落地的全过程实践。建议读者结合代码示例与GUI操作,理解数据预处理、多目标优化、混合整数求解与结果评价的关键步骤,并通过修改权重参数、运行场景与设备配置进行灵敏度分析,从而全面掌握光储充系统优化的核心逻辑与应用潜力。 立即下载

相关推荐

一码盾・EXE 软件一机一码加密授权系统|机器绑定+离线授权码,防复制防破解,支持试用期 次数 有效期,批量发卡,软件加密软件

一码盾(DFG EXE 加密盾 旗舰版)是一套给任意 EXE 加壳加密、按 “一机一码” 发放授权的工具,面向个人开发者、软件作者和小型工作室。 加密时把主程序连同 DLL、bin 目录、配置文件一起打包,用 AES-256-CBC 加密后追加到壳程序末尾,成品里查不到明文代码;文件尾部带 SHA256 校验,壳模板也会自校验,改一个字节就拒绝启动,同时检测调试器,防止用 patch 跳过授权。原程序只在授权通过后才释放到临时目录运行,退出即删。 授权采用一机一码机制:客户双击成品后,会先看到启动面板,上面显示由 CPU、主板、BIOS、系统盘、显卡算出的 16 位机器码;客户复制后发给你,你用注册机粘贴出码,再由他填入激活。支持永久、按天数、按次数三种授权,试用次数用完就必须激活,删掉试用文件也刷不出新次数,把系统时间往前改也没有用。 每个产品都会随机生成一把独立密钥,界面上只显示 8 位指纹。A 产品的注册机出的码,在 B 产品上验不过;单个注册机的密钥被逆向出来,也不会影响其它产品;注册机还可以加口令,防止它外泄后被人乱出码。密钥库用 DPAPI 加密,注册机文件丢了,点 “重新导出” 就能补回。 面板可以按你的品牌来定:公告、微信、QQ、邮箱、跳转链接、6 个预设主题色加任意取色,有完整版和精简版两种样式,还能设成已激活就直接进程序、不弹面板。全程离线运行,不需要服务器,也不用客户联网。 工具是单文件,Win10、11 自带 .NET Framework 4.7.2 就能运行,另外支持用命令行或 spec.json 批量加密,用注册机命令行批量出码,还有 42 项端到端自检,并附完整 C# 源码和一键编译脚本,方便二次开发。

使用 Rational XDE Data Modeler 建模和设计数据库(转自IBM)

使用 Rational XDE Data Modeler 建模和设计数据库 第二部分内容:简介逻辑数据建模物理数据建模和 DB2 UDB 的集成逆向工程同步工具

Hsu Tsing 好好学习,天天快乐 2090

ORCA灵巧手工程文件

包括软件包、用户手册、3D模型、上位机等资料

IBM WebSphere 开发者技术期刊: 开发用于 WebSphere Application Server 的 Hibernate 应用程序(转自IBM)

IBM WebSphere 开发者技术期刊: 开发用于 WebSphere Application Server 的 Hibernate 应用程序内容:前言使用 Hibernate通过 WebSphere Application S

Hsu Tsing 好好学习,天天快乐 1587

隔离型全桥LLC谐振变化器建模及参数设计资料【仿真+设计报告+计算书】

内容概要:本文系统阐述了隔离型全桥LLC谐振变换器的建模与参数设计方法,聚焦于2.5kW双向全桥LLC变换器的工程实现,涵盖变频与移相混合控制策略的原理与应用。资料包包含完整的Simulink闭环仿真模型、Mathcad计算书及详细的设计报告,深入解析了软开关技术、谐振参数优化、双闭环PI控制等核心技术,并结合控制理论展示了高频高效电源转换系统的设计流程与仿真调试方法。; 适合人群:具备电力电子与电力传动基础知识,从事开关电源、新能源变换器研发的工程师及高校研究生。; 使用场景及目标:①掌握全桥LLC谐振变换器的工作原理与数学建模方法;②学习基于Simulink的闭环控制系统设计与动态响应分析;③实现变频与移相混合控制策略下的谐振参数优化与系统稳定性调试;④应用于科研项目、毕业设计或工业产品开发中的高性能电源系统设计。; 阅读建议:此资源以仿真与计算为核心,建议读者结合提供的Simulink模型与Mathcad计算书同步操作,深入理解控制逻辑与参数设计流程,并通过调整谐振腔参数、观察闭环响应来强化实践能力。

蚊虫幼虫群及滋生地识别病媒生物检测数据集VOC+YOLO格式2868张3类别.md

【重要提示】本页面仅为资源介绍,不含外部下载地址 亲爱的 优快云 用户: 感谢你浏览本资源页面,在这里提前向大家说明相关情况,避免后续产生误解。本资源我设置的初衷是 0 积分免费分享文档介绍,希望可以无偿给到有需要的朋友。但 优快云 平台存在自动调控机制,系统会根据资源下载热度、文件体积、平台规则等因素,自动修改资源所需下载积分,页面显示为 1 积分、2 积分或更高积分都属于平台自动调整结果,并非我手动修改设置,我没有权限自主锁定积分数值。 如果你打开页面后,发现下载所需积分不为 0,请务必谨慎考虑是否下载。一旦你支付积分完成下载,后续遇到资源内容和描述不符、文件损坏等问题,我无法承担对应的积分损失,也没有渠道为你办理积分退还。在此强烈建议,只有页面明确显示 0 积分的时候,再进行下载操作。 同时特别说明:这份资源介绍文案里,没有附带任何外部下载地址。资源本身是通过 优快云 官方上传通道上传的附件,正常情况下直接点击页面自带的下载按钮即可获取文件。页面找不到外部下载链接属于正常情况,并非资源缺失。 如果因为平台积分显示异常,导致你被扣取积分,积分退款、积分异常相关问题,请直接联系 优快云 官方客服咨询处理。平台规则由官方制定,我无法干预积分变动,望各位理解。

hotmail升级啦!

一早来公司,同事说他的hotmail编程250M了~我赶紧上去一瞧,呵呵~不出所料,我的变成了2000M,真是太爽了,1% / 2000MBhotmail一直比测试阶段的Gmail要稳定的多。反垃圾也比较出色。 免费 使用免费的if (!ccTest(DH_BC))document.write("span.cc46 {display:inline!i

Hsu Tsing 好好学习,天天快乐 1535

CR660x-4.4.198.9-100刷机固件

根据bs://gb.cmMelRla/deva-4.4编译所得,适用于CR660X,建议刷第3方不死后进行升级。不死教程自行寻找。

Net平台和Websharp框架 专题讲座(免费)

Net平台和Websharp框架 专题讲座Websharp的目标 设计一个基于.Net的通用的应用软件系统的框架,以简化基于.Net平台的企业应用软件的开发. Websharp的整体结构. Websharp适用于.Net环境下的分布式应用系统的开发. 主要设计思路及涉及的技术在数据库访问部分,使用了ADO.Net和工厂模式;在ORM部分,使用了动态代码生成和即时编译,以及对Data

Hsu Tsing 好好学习,天天快乐 1433

【无人机协同】动态环境下多无人机系统的协同路径规划与防撞研究(Matlab代码实现)​

内容概要:本文围绕基于变频控制的多相交错LLC谐振变换器闭环仿真模型展开研究,系统阐述了多相交错并联技术在降低输出电流纹波与提升功率密度方面的优势,深入分析了交错角对纹波对消的影响及均流问题的成因。针对LLC谐振变换器在变频控制下的强非线性特性,研究采用扩展描述函数(EDF)进行小信号建模,克服了传统状态空间平均法在非线性系统中建模精度不足的缺陷,并在此基础上设计了输出电压外环PID控制器。通过Simulink仿真平台,对系统的稳态性能、启动过程、负载阶跃响应及频率调节的平滑性进行了全面验证,确保系统在动态工况下仍能维持软开关运行边界,提升了变换器的整体效率与稳定性。该研究为高频、高效率、低纹波电源系统的设计与优化提供了坚实的理论依据与实践指导。; 适合人群:具备电力电子、自动控制理论基础,从事开关电源、新能源变换器、高频电源系统或电力电子系统仿真的科研人员及工程师,特别适合电气工程、自动化等相关专业的研究生及工作1-3年的研发人员。; 使用场景及目标:①掌握多相交错LLC谐振变换器的工作原理及其在纹波抑制与功率扩容中的关键技术;②学习针对强非线性系统的EDF小信号建模方法,理解其在闭环控制器设计中的应用价值;③通过仿真模型复现与参数调试,提升对LLC变换器动态响应、稳定性分析与PID参数整定的实践能力; 阅读建议:建议结合文中提供的仿真模型与参数设计报告,逐步完成从建模、控制器设计到仿真验证的全流程操作,重点关注EDF建模的推导过程与闭环系统在不同工况下的动态响应表现,以深入理解高频谐振变换器的控制机理与工程实现要点。

horizon-j6-open-explorer-3.0.22-compiled-doc.zip

horizon-j6-open-explorer-3.0.22-compiled-doc.zip

应用IBM Rational XDE 和 WebSphere Studio创建电子商务应用(转自IBM)

应用IBM Rational XDE 和 WebSphere Studio创建电子商务应用 内容: 简介获取需求创建项目和模型添加用例创建时序图表示行为创建EJB项目逆向工程EJB项目测试应用鸣谢

Hsu Tsing 好好学习,天天快乐 1397

TransUnet官方代码训练自己数据集(彩色RGB3通道图像的分割)

官方代码:https://github.com/Beckschen/TransUNet 目的:训练5个类别的汽车部件分割任务(测试在另一篇博客中) 实现效果: 1. github下载代码,并解压。 项目里的文件可能跟你下载的不一样,不急后面会讲到! 2. 配置数据集(尽最大努力还原官方数据集的格式)。 通常自己手上的数据集分images和labels文件夹,分别存放着原始图像和对应的mask图像,如下图所示; mask图像中的像素有0,1,2,3,4 分别代表背景,车身,轮子,车灯,窗户,一共五个

qq_37652891的博客 5万+

IBM 易捷产品免费讲座 (张江)

内容简介   本讲座是IBM(中国)有限公司软件部和上海浦东软件园面向软件开发团队推出的免费技术讲座。IBM 推出一系列专为中小型企业量身打造的产品和解决方案。该系列产品将标记“Express”名字。Express 易捷系列中小型企业解决方案,专门针对中小型企业客户的需求进行设计、开发和定价,提供业务问题的解决方案,帮助客户成为随需应变的企业。同样,对于企业在开发J2EE系统过程中,如何按

Hsu Tsing 好好学习,天天快乐 1346

AI脸部替换Roop-Unleashed,一键整合包教程

Roop-Unleashed是一个无须训练模型的深度伪造工具,专为图像和视频的面部替换而设计。它通过简洁的浏览器界面提供用户友好且跨平台的使用体验,无论用户是业余爱好者还是专业人士,都能快速上手。它无需复杂的设置即可实现高效的处理和转换,使图像和视频的编辑变得更加轻松和便捷。

m0_72580657的博客 1万+

基于Playwright的雪球网股票情绪数据自动化采集实战

网络爬虫是自动化获取互联网公开数据的关键技术,其核心原理在于模拟浏览器行为或直接发送HTTP请求以解析网页内容。在金融科技与量化分析领域,实时、稳定的数据源具有极高的技术价值,能够为市场情绪分析、因子挖掘提供基础。面对采用动态加载、复杂反爬机制的现代单页应用,传统的请求库与Selenium方案在稳定性与隐蔽性上面临挑战。本文聚焦于利用Playwright这一现代浏览器自动化工具,通过模拟真实用户交互、监听网络请求,构建一个能够稳定采集雪球社区实时讨论热度的解决方案。该方案不仅解决了动态内容渲染问题,还通过请

weixin_42529328的博客 585

“UML与OOAD”免费讲座(张江)

方便的朋友可以去看看                                                                 “UML与OOAD”  讲座简介  本讲座 是 Rational用户组,UML软件工程组织,火龙果软件工程技术中心(北京、上海)联合IBM developerWorks ,IBM软件部,每月定期面向软件开发团队推出的软件工

Hsu Tsing 好好学习,天天快乐 1258

卷积神经网络-猫狗识别(附源码)

利用python实现一个卷积神经网络,训练猫狗数据集,实现对猫狗图片的预测识别

m0_63223213的博客 2万+

Apache Geronimo 1.0 M3 Released

 Apache Geronimo 1.0 M3 ReleasedThe Apache Geronimo team is proud to announce the 1.0 M3 release of the Geronimo application server. FeaturesCMP Entity beans are now supported. However, ther

Hsu Tsing 好好学习,天天快乐 1021

SAP 物料的分割评估

SAP 物料的分割评估 前言 本文主要讲解SAP中物料的分割评估,通过分割评估来区分出同一物料不同来源下的核算方式。例如:同一物料分为自产或者采购,或者同一物料分为进口或者国内采购等。 一、概述 分割评估一般用于以下场景: 1、物料分为内部采购和外部采购; 2、物料分属于进口或者国内采购; 3、物料分属于不同的批次; 4、物料分为自制或者采购。 由于物料的来源不同可能导致物料的价格或者性质不同,需要用不同价格来区分出 二、配置步骤 1.激活分割评估 ...

五谷散熊 6792

PyTorch深度学习实战(7)——批大小对神经网络训练的影响

在神经网络中,批( batch )是指一次输入网络进行训练或推断的一组样本。批处理( batch processing )是指将这一组样本同时输入网络进行计算的操作。本节中首先介绍批( Batch )的基本概念,并且介绍批大小在神经网络训练过程中的影响。

盼小辉丶的博客 1万+

获取各种CGI环境变量

这两天有朋友问我怎么取环境变量,想想以前用PHP,很简单就可以用phpinfo()取到了,JAVA会麻烦一点。找了一下,找到以前收藏过一个例程。 String strEnvs[][] = { {"CONTENT_LENGTH",String.valueOf(request.getContentLength())}, {"CONTENT_TYPE",request.getCont

Hsu Tsing 好好学习,天天快乐 930

【Unity程序技巧】Unity中单例模式管理器

单例模式(Singleton Pattern)是 最简单的设计模式之一

秩沅 1659
上一篇: Apache Geronimo 1.0 M3 Released
下一篇: 假期已经被批复
stemart
博客等级 码龄22年 0粉丝 26原创
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

个

红包个数最小为10个

元

红包金额最低5元

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

抵扣说明:

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

余额充值