ant打包中报错,跪求解答

ant的build.xml中使用的是
但是运行命令行时报错:[java] THIS TOOL IS DEPRECATED. See --help for more information.

不能进行打包

1个回答

Csdn user default icon
上传中...
上传图片
插入图片
抄袭、复制答案,以达到刷声望分或其他目的的行为,在CSDN问答是严格禁止的,一经发现立刻封号。是时候展现真正的技术了!
其他相关推荐
使用ant打包报错
报以下的错 build.xml:649: The following error occurred while executing this line: build.xml:694: null returned: 1 解决 在执行ant打包命名之前,先clean一下 ant clean
【疑难问题】,跪求解答>【疑难问题】,跪求解答>【疑难问题】,跪求解答>
未能从程序集 Service, Version=1.0.2670.31267, Culture=neutral, PublicKeyToken=null 中加载类型 AMS.Service.System.EquipProjectServiceImpl。 rn说明: 执行当前 Web 请求期间,出现未处理的异常。请检查堆栈跟踪信息,以了解有关该错误以及代码中导致错误的出处的详细信息。 rnrn异常详细信息: System.TypeLoadException: 未能从程序集 Service, Version=1.0.2670.31267, Culture=neutral, PublicKeyToken=null 中加载类型 AMS.Service.System.EquipProjectServiceImpl。rn
IDEA使用Ant打包报错解决方法
在IDEA中项目使用Ant打包报错 报错如下: at org.apache.tools.ant.taskdefs.Javac.compile(Javac.java:1365) at org.apache.tools.ant.taskdefs.Javac.execute(Javac.java:1070) at org.apache.tools.ant.UnknownElement.execute(U...
跪求解答:图像拼接怎么执行总是报错?
rn拼接代码如下:rnrn% load input imagesrnI1 = double(imread('G:/left.jpg'));rn[h1 w1 d1] = size(I1);rnI2 = double(imread('G:/right.jpg'));rn[h2 w2 d2] = size(I2);rn rn% show input images and prompt for correspondencesrnfigure; subplot(1,2,1); image(I1/255); axis image; hold on;rntitle('first input image');rn[X1 Y1] = ginput2(2); % get two points from the userrnsubplot(1,2,2); image(I2/255); axis image; hold on;rntitle('second input image');rn[X2 Y2] = ginput2(2); % get two points from the userrnrn% estimate parameter vector (t)rnZ = [ X2' Y2' ; Y2' -X2' ; 1 1 0 0 ; 0 0 1 1 ]'; rnxp = [ X1 ; Y1 ];rnt = Z \ xp; % solve the linear systemrna = t(1); % = s cos(alpha)rnb = t(2); % = s sin(alpha)rntx = t(3);rnty = t(4);rnrn% construct transformation matrix (T)rnT = [a b tx ; -b a ty ; 0 0 1];rnrn% warp incoming corners to determine the size of the output image (in to out)rncp = T*[ 1 1 w2 w2 ; 1 h2 1 h2 ; 1 1 1 1 ]; rnXpr = min( [ cp(1,:) 0 ] ) : max( [cp(1,:) w1] ); % min x : max xrnYpr = min( [ cp(2,:) 0 ] ) : max( [cp(2,:) h1] ); % min y : max yrn[Xp,Yp] = ndgrid(Xpr,Ypr);rn[wp hp] = size(Xp); % = size(Yp)rnrn% do backwards transform (from out to in)rnX = T \ [ Xp(:) Yp(:) ones(wp*hp,1) ]'; % warprnrn% re-sample pixel values with bilinear interpolationrnclear Ip;rnxI = reshape( X(1,:),wp,hp)';rnyI = reshape( X(2,:),wp,hp)';rnIp(:,:,1) = interp2(I2(:,:,1), xI, yI, '*bilinear'); % redrnIp(:,:,2) = interp2(I2(:,:,2), xI, yI, '*bilinear'); % greenrnIp(:,:,3) = interp2(I2(:,:,3), xI, yI, '*bilinear'); % bluernrn% offset and copy original image into the warped imagernoffset = -round( [ min( [ cp(1,:) 0 ] ) min( [ cp(2,:) 0 ] ) ] );rnIp(1+offset(2):h1+offset(2),1+offset(1):w1+offset(1),:) = double(I1(1:h1,1:w1,:));rnrn% show the resultrnfigure; image(Ip/255); axis image;rntitle('mosaic image');rnrnrn------------------------------------------------------------------------------------------------rnfunction [X, Y] = ginput(n)rnrnX = [];rnY = [];rnfor i=1:n,rn [px py ] = ginput(1);rn X = [X ; px];rn Y = [Y ; py];rn plot( px, py, 'r+' );rn text_handle = text( px+5, py, num2str(i) );rn set(text_handle,'Color',[1 1 1])rnendrnrnrnrnrn执行后总是报错:rn??? Input argument "ExtrapVal" is undefined.rnrnError in ==> interp2>linear at 355rnif length(sout)>0, F(sout) = ExtrapVal; endrnrnError in ==> interp2 at 86rn zi = linear(varargin1:end-index, ExtrapVal);rnrnError in ==> mosaic at 41rnIp(:,:,1) = interp2(I2(:,:,1), xI, yI, '*bilinear'); % redrnrnrnrn这是怎么回事呢?跪求解答rnrnrnrnrnrnrn
python字典传值报错,跪求大佬解答
[code=python]class C:rn def B(self,**dict):rn print(dict)rn print(dict.values)rn def D(self,para=None,**dict):rn print(dict)rn print(dict.keys())rnif __name__ == '__main__':rn dict0='a':1,'b':2rn e=C()[face]qq:3.gif[/face]rn e.D(dict0)rn print(dict0.keys())rn e.B(dict0)rn[/code]rn运行结果如下:rn[code=python]rndict_keys([])rndict_keys(['a', 'b'])rnTraceback (most recent call last):rn File "C:/Users/xxx/1212.py", line 13, in rn e.B(dict0)rnTypeError: B() takes 1 positional argument but 2 were given[/code]rnrn跪求大佬解答疑问:rn1、为什么e.D(dict0)结果是空字典?[face]qq:3.gif[/face]rn2、e.B(dict0)结果报错位置参数传多了?[face]qq:3.gif[/face]rn
MySQL函数执行报错,跪求大神解答
执行如下语句时报错rnSELECT fun_split_version('03.02')rnrn报错信息如下:rn错误代码: 1366rnIncorrect decimal value: '' for column '' at row -1rnrn很神奇的一点就是,在多个服务器上的数据库(数据库版本都是5.5.20)同样执行时,只有一个报错,特纠结rnrn函数如下:rnrnDELIMITER $$rnrnUSE `autelproweb`$$rnrnDROP FUNCTION IF EXISTS `fun_split_version`$$rnrnCREATE DEFINER=`root`@`%` FUNCTION `fun_split_version`(softVer VARCHAR(50)/*版本号*/) RETURNS DECIMAL(20,0)rnBEGINrnDECLARE returnVer DECIMAL(20, 0); rnDECLARE v_1 DECIMAL(5);rnDECLARE v_2 DECIMAL(5);rnDECLARE v_3 DECIMAL(5);rnDECLARE wz1begin INT; DECLARE wz1 INT;DECLARE wz2 INT ;DECLARE wz3 INT;DECLARE wz4 INT;rnDECLARE softVer2 VARCHAR(50); rnSET wz1begin = INSTR(softVer,'v'); # 取V所在的字符 一般为1rnSET wz1=INSTR(softVer,'.'); # 取第一个点所在的位置rnSET wz2=LOCATE('.', softVer, wz1+1); # 取第二个点所在的位置rnIF wz2<1 THENrn SET wz2=CHAR_LENGTH(softVer)+1; # 不存在最后一个点则取最后一位+1为最后一个点rnEND IF;rn rnSET v_1=CONVERT(SUBSTRING(softVer,wz1begin+1,wz1-1-wz1begin), DECIMAL(5,0));rnSET v_2=CONVERT(SUBSTRING(softVer,wz1+1,wz2-wz1-1), DECIMAL(5,0));rnSET v_3=CONVERT(SUBSTRING(softVer,wz2+1,CHAR_LENGTH(softVer)-wz2), DECIMAL(5,0));rnSET returnVer=v_1*10000000000+v_2*100000+v_3;rnRETURN returnVer;rnEND$$rnrnDELIMITER ;
ANT打包
&amp;#13; u       Ant 的下载 &amp;#13;        Ant 是一个开源、免费的软件,可以从以下地址下载最新版本: &amp;#13;               http://ant.apache.org/ &amp;#13; u       Ant 的安装和配置 &amp;#13;        Ant 的安装程序是一个压缩文件,例如最新版本的 Ant 1.6.5 安装程序文件名...
跪求,解答
怎么样在程序初始化加载sqllite数据库里的所有表啊
跪求解答
HTTP Status 500 - rnrn--------------------------------------------------------------------------------rnrntype Exception reportrnrnmessage rnrndescription The server encountered an internal error () that prevented it from fulfilling this request.rnrnexception rnrnorg.apache.jasper.JasperException: Exception in JSP: /Jsp/dtree/Bbs.jsp:83rnrn80: rn81: String szSql="select * from TBL_Bbs_Type order by Ord ";rn82: rn83: ConpoolRs Conpoolrs=myDBCtrl.DBAsk_ResultSet(szSql);rn84: rs=Conpoolrs.result;rn85: rn86: int i=0;rnrnrnStacktrace:rn org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:451)rn org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:373)rn org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:329)rn org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)rn javax.servlet.http.HttpServlet.service(HttpServlet.java:729)rnrnrnroot cause rnrnjava.lang.NullPointerExceptionrn com.dbctrl.DBCtrl.DBAsk_ResultSet(DBCtrl.java:335)rn org.apache.jsp.Jsp.dtree.Bbs_jsp._jspService(Bbs_jsp.java:128)rn org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:98)rn javax.servlet.http.HttpServlet.service(HttpServlet.java:729)rn org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:331)rn org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:329)rn org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)rn javax.servlet.http.HttpServlet.service(HttpServlet.java:729)rnrnrnnote The full stack trace of the root cause is available in the Apache Tomcat/5.5.27 logs.rnrnrn--------------------------------------------------------------------------------rnrnApache Tomcat/5.5.27
跪求解答!
我创建了一个ActiveX ControlWizard工作区,以下是我的语句rn void CTest2PropPage::OnButton3() rnrn rn CDatabase db;rn db.Open(NULL,FALSE,FALSE,"ODBC;DSN=db1;UID=3515;PWD=3515");rn CRecordSet dbmy(&db);rn……rn但是编译出错说:error C2065: 'CRecordSet' : undeclared identifierrn是什么原因啊?我的vc有问题还是在ocx中使用ODBC有其他要注意的?rn#include "afxdb.h"我加入后也没有效果。一样报错
跪求解答!!
在lookUserInfo.jsp页面中有rn修改资料rn在modifyUser.jsp页面中有如下rn用户名: rn为什么页面显示用户名这里为空呢?rn在modifyUser.jsp页面该如何取从lookUserInfo.jsp中传来的username呢?
跪求解答。。
[url=http://topic.csdn.net/u/20120206/10/ce766199-aafc-4361-8c44-0099eaf3ec9a.html]http://topic.csdn.net/u/20120206/10/ce766199-aafc-4361-8c44-0099eaf3ec9a.html[/url]rnrn
ant打包
这是重量级架构的打包视频
ant打包中中文问题
最近在整体打包平台时发现一个问题,就是当jad.midlet.name和jad.name为3个中文时,打包失败(4个5个中文时没有任何问题);打开JAR包发现MANIFEST.MF文件中出现乱码问题,jad中中文显示正常,最近碰到需要打包的项目为3个中文,每次打出来后都需要手动修改MANIFEST.MF文件,这样太麻烦,特请假高手解决....
ant打包sdk中build.xml
ant打包时,由于sdk版本较低,可能打包失败,需要覆盖sdk目录下的buil.xml文件
ant打包中的build.xml
http://www.cnblogs.com/uncle2000中的关于ant打包的博客中的资源
跪求高手解答!!!
求高手解决如何用一个芯片同时取代3个AD620
100分跪求解答。。。
环境:rnSTRUTS1。2+hibernate3.1+oracle9+myeclipse5.1rn先把我的配置文件贴出来:rnrn rnrn rn rn rn factory rn org.apache.commons.dbcp.BasicDataSourceFactoryrn rn rn driverClassName rn oracle.jdbc.driver.OracleDriverrn rn rn urlrn jdbc:oracle:thin:@localhost:1521:youjiern rn rn usernamern scottrn rn rn passwordrn tigerrn rn rn maxActivern 10rn rn rn maxIdlern 10rn rn rn maxWaitrn -1rn rn rnrnrnrntomcat里server.xml连接池配置rnrn下面是hibernate.cfg.xml配置文件rnrnrnrnrnrnrnrn truern rn java:/comp/env/jdbc/testoraclern rn rn org.hibernate.dialect.Oracle9Dialectrn rn rn rnrnrnrnrn说明:rn之前我一直没有用连接池连接数据库一切正常,rn但是我把所有做完之后想把数据库连接方式换成连接池来连接rn之后就出现如下异常:rnjavax.servlet.ServletException: Cannot open connectionrn org.apache.struts.action.RequestProcessor.processException(RequestProcessor.java:523)rn org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:421)rn org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:224)rn org.apache.struts.action.ActionServlet.process(ActionServlet.java:1194)rn org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:432)rn javax.servlet.http.HttpServlet.service(HttpServlet.java:709)rn javax.servlet.http.HttpServlet.service(HttpServlet.java:802)rnrnroot causernrnorg.hibernate.exception.GenericJDBCException: Cannot open connectionrn org.hibernate.exception.SQLStateConverter.handledNonSpecificException(SQLStateConverter.java:103)rn org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:91)rn org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:43)rn org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:29)rn org.hibernate.jdbc.ConnectionManager.openConnection(ConnectionManager.java:420)rn org.hibernate.jdbc.ConnectionManager.getConnection(ConnectionManager.java:144)rn org.hibernate.jdbc.AbstractBatcher.prepareQueryStatement(AbstractBatcher.java:105)rn org.hibernate.loader.Loader.prepareQueryStatement(Loader.java:1561)rn org.hibernate.loader.Loader.doQuery(Loader.java:661)rn org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:224)rn org.hibernate.loader.Loader.doList(Loader.java:2145)rn org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2029)rn org.hibernate.loader.Loader.list(Loader.java:2024)rn org.hibernate.loader.hql.QueryLoader.list(QueryLoader.java:375)rn org.hibernate.hql.ast.QueryTranslatorImpl.list(QueryTranslatorImpl.java:308)rn org.hibernate.engine.query.HQLQueryPlan.performList(HQLQueryPlan.java:153)rn org.hibernate.impl.SessionImpl.list(SessionImpl.java:1106)rn org.hibernate.impl.QueryImpl.list(QueryImpl.java:79)rn com.youjie.daoimpl.PersonDAOIMPL.isLogin(PersonDAOIMPL.java:26)rn com.youjie.struts.action.LoginAction.login(LoginAction.java:46)rn sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)rn sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)rn sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)rn java.lang.reflect.Method.invoke(Method.java:585)rn org.apache.struts.actions.DispatchAction.dispatchMethod(DispatchAction.java:274)rn org.apache.struts.actions.DispatchAction.execute(DispatchAction.java:194)rn org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:419)rn org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:224)rn org.apache.struts.action.ActionServlet.process(ActionServlet.java:1194)rn org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:432)rn javax.servlet.http.HttpServlet.service(HttpServlet.java:709)rn javax.servlet.http.HttpServlet.service(HttpServlet.java:802)rnrnrn我肯定我的数据库服务是开了的。数据库驱动放在了webinf/lib里面rnrn谁知道这是什么原因吗????
高分跪求高手解答!!!
小弟现在的情况是这样的:在主页面(a.html)中有一个iframe连接到另外一个网站的一块页面(b.html),在主页面(a.html)被加载时,能不能不使状态栏上出现(b.html)的网址。。现在是加载时会闪一下,老板说不能闪,不能出现,这个问题要怎么解决啊?rnrn另:网站是asp.net做的。
简单问题跪求解答
在sql-server2000中如何实现数据库同步功能,两台机器在广域网上能实现吗,立解立给分^_^
跪求高手解答!!
(1)利用指针变量和字符数组,编一个程序将输入的一行字符串中所有的汉字删除
小弟初学跪求解答
怎样把一个JAVA文件,在JBuilder中,让它生成一个.exe文件.
跪求各位前辈解答
小弟公司招收一个ASP.NET的程序员,工作主要是维护和更新,所以也加上了要会Photoshop,语言用的是c#。我是计算机专科毕业,学校学的估计派不上用场了,再加上毕业3年都没去碰这个东西了。相当的生疏,在这里请教各位前辈,做短期的ASP.NET的突破去把这个工作揽下来需要多少时间的努力,再者需不需要系统的学习。主要是过了面试然后边工作边学习,我是这样计划的~!!希望得到前辈们的指点,小弟在这里先谢谢了.
sql题目 跪求解答
article表rnrnarticleid title authorrn1 abc 张三rn2 dfg 李四 rn3 jkl 王五rn4 zxv 王五rnrnversion表rnrnarticleid version amendmentor amenddatern1 1 张三 2008-2-5rn1 2 张三 2008-2-8rn2 1 李四 2008-2-6rn2 2 张三 2008-3-6rn2 3 李四 2008-3-15rn3 1 王五 2008-3-8rn4 1 王五 2008-3-6rn4 2 王五 2008-3-10rn rnrn求取每篇文章(标题)最后更新的版本号和修订日期,并写出结果。rnrnrn
跪求高手解答 !
webservice 链接一个dbf库,dbf库是实时刷新变化的,但通过网页访问老是显示一致的数据,貌似从缓存里取的数值,导致通过网页浏览无法刷新最新的数据,请问大家这个问题怎么解决。通过vs2010做的webservice
英文题目跪求解答
给了四个hpp文件,要求编辑出对应的四个对应的cpp文件,每一块都有相应注释,要求用pointer互指,使make.cpp可以成功compile。编译环境最好是linux(g++)。输出结果应为true或false。跪求解答。题目要求如下:rnrnThis is the main exercise. As mentioned, the exercise practices copy construction. But it also has some aspects of input reading. You are asked to implement a package that will allow to implement a simple satisfiability solver (look up sat solving, links recommended by Alexey here and here). Essentially, the data structure implements a Boolean formula over Boolean variables in a certain format (CNF). The functionality that is added is particularly suitable to implement (very basic) solvers that can tell whether a given formula has an assignment that renders the formula true. 
The classes that are required are:rn1. Variable - a Boolean variable. A variable may be unset, which means that it's value is (currently) unknown, or set, in which case it is either true or false.rn2. Literal - this is either a variable or a negated variable.rn3. Clause - this is a disjunction of literals. In our package the clause is an array of literals. It has to be memory efficient (i.e., not allocate space for more literals than it actually has). 
In more efficient sat solvers, when a variable is set it notifies all the clauses in which it appears. For that, our variables are going to contain pointers to the clauses that contain them. Again, the Variable should not allocate more space than required for storing these pointers.rn4. Formula - this is the main class here. A formula is the conjunction of a set of clauses. It also contains all the variables that appears in these clauses in order to coordinate the solving process. Again, the containers in the Formula should not be larger than required.rnNotice that some of the options are quite advanced. For example, force in Clause, and resolve in Formula. As mentioned, the main point of the exercise is in the copy constructor of Formula. So you should invest most of your effort in that. If the different copy constructors work fine, then proceed to the more advanced options that go in the direction of sat solving.rnTechnically, I have created the header files of all these classes. You have to complete them with additional members and complete the implementations. You will have to submit eight files: Variable.*pp, Literal.*pp, Clause.*pp, and Formula.*pp. You can submit one additional file called Solver.cpp. This file can contain your own version of a sat solver that improves on the one that I included below. The Solver.cpp file has to contain a main and it will be compiled using the same Makefile that is supplied below. The header files include detailed descriptions of the functions that you are required to implement.rnrn下面是四个hpp文件和main.cpp文件:rnVariable.hpp:rn/*rn * Variable.hpprn *rn * Created on:rn * Author:rn */rnrn#ifndef VARIABLE_HPP_rn#define VARIABLE_HPP_rnrn#include rn#include rnrnclass Variable;rnrn#include "Clause.hpp"rnrnclass Variable rnpublic:rn // This is a basic Boolean variablern // It has an ID and is either set or unset (i.e., known or unknonw)rn // If it is set, it can be true or falsern // It also holds pointers to all the clauses that it appearsrn // in.rn Variable();rnrn // Initializes the identifierrn // The identifier of a real variable cannot be 0!rn Variable(unsigned int);rnrn // Copies the identifier and the status of the variablern // Does not copy the clauses (deep copy is orchestrated byrn // formula)rn Variable(const Variable &);rnrn // Clean you messrn ~Variable();rnrn // Return the value of the variablern // If the variable is not set return whatever you wantrn bool value() const;rnrn // Return whether the variable is set or notrn bool isSet() const;rnrn // Set the variable to the given valuern void set(bool);rnrn // Unset the variablern void unset();rnrn // Update the list of clauses in which the variable appearsrn void addedToClause(Clause* cl);rnrn // In how many clauses does the variable appearrn unsigned int numClauses() const;rnrn // Return a pointer to the i-th clause the variablern // is in.rn // Or NULL if there is no such clausern Clause* clause(unsigned int);rnrn // Return the idrn unsigned int id() const;rnrn // output ?/0/1 accoring to the set/unset value.rn std::string toString() const;rnprivate:rn // Add your own data members and member functions.rn;rnrnstd::ostream& operator<<(std::ostream&, const Variable&);rnrn#endif /* VARIABLE_HPP_ */rnrnFormula.hpp:rnrn/*rn * Formula.hpprn *rn * Created on:rn * Author:rn */rnrn#ifndef FORMULA_HPP_rn#define FORMULA_HPP_rnrn#include rn#include rnrnclass Formula;rnrn#include "Clause.hpp"rn#include "Variable.hpp"rnrn// A formula has a given set of variablesrn// and clauses that use these variables.rn// The total data structure that we are developing has a formularn// but it also contains a partial assignment to thern// variables appearing in the formula.rn// The assignment is partial as some variables could bern// unset.rn//rn// The partial assignment may be sufficient to deduce thatrn// the formula is satisfied but in most cases it is not sufficient.rn//rn// In case that the partial assignment is not sufficient therern// may be a fuller assignment that does satisfy the formula.rn// A SAT solver (see main.cpp) tries to extend thern// current assignment to a fuller assignment that satisfiesrn// the formula.rn//rn// Some of the functions, such as resolve(), tries to increasern// the assignment to a fuller assignment based on thern// constraints that the formula induces.rn//rnclass Formula rnpublic:rn Formula();rn // A deep copy.rn // This deep copy should orchestrate all the other classes sorn // that you get a deep copy of the entire formula.rn Formula(const Formula&);rnrn // Clean your messrn ~Formula();rnrn // If the variable exists returns truern // If the variable does not exist adds it andrn // return falsern bool addVar(unsigned int);rnrn // returns false if the variable does not existrn // If the variable does exist sets the pointerrn // reference to the pointer to this variablern bool findVar(unsigned int, Variable*&) const;rnrn // Returns the id of an unset variablern // If there is no unset variable it returns 0.rn unsigned int firstUnsetVar();rnrn // Adds a clause of size sizern // The values in the array are the identifiersrn // of the variables.rn // The identifier has negative value if it is negatedrn // it has positive value if it is not negatedrn void addClause(unsigned int size, int* array);rnrn // Set the variable id to the valuern // If the variable does not exist return falsern // Otherwise set the variable and return truern bool setVar(unsigned int id,bool value);rnrn // Unset the variable idrn // If the variable does not exist return falsern // Otherwise set the variable and return truern bool unsetVar(unsigned int id);rnrn // Return the value of variable idrn // If there is no such variable return falsern bool value(unsigned int id);rnrn // Is variable id set?rn // If there is no such variable return falsern bool isSet(unsigned int) const;rnrn // Is the formula satisfied?rn // The formula is satisfied if all the clauses in it arern // satisfiedrn bool sat() const;rnrn // Go over all clauses and check if some clausern // forces the value of a variable.rn // If it does then set the value to the forced value.rn // Continue until no more resolutions are possible.rn void resolve();rnrn // Output the formula in dimacs format (see below)rn // You can write whatever you want as initial commentsrn std::string toString() const;rnrn // Read a formula in dimacs formatrn // A formula can start with several lines of commentsrn // that are identified by the first character 'c'rn // You should ignore these lines.rn // Then, the formula has a line of the format:rn // p cnf numVars numClausesrn // numVars is the number of variables in the formularn // numClauses is the number of clauses that you need to readrn //rn // No comments appear after this line with prn // The only thing that appears from now on are numbersrn // according to the format explained below. If anythingrn // else appears the reading should fail and the streamrn // should be left with an error state.rn //rn // Then there is a list of clauses each in a separate linern // The structure of a clause is:rn // number number number .... number 0rn //rn // That is, you have a sequence of identifiers as positive or negativern // numbers.rn // The sequence ends with a 0.rn // You are allowed to ignore whatever appears after the 0 untilrn // the next line.rn // Line length is bounded by 1000.rn // This sequence represents a clause in which:rn // If the number is negative (e.g., -5) this means that therern // is literal with a negated variable of the identifier thatrn // matches the absolutern // value of the number (5 in the example).rn // If the number is positive (e.g., 5) this means that therern // is a literal with a varialbe of the identifier thatrn //rn // If there are faults during reading the formula you should leavern // the formula in parameter (reference) unchanged and leave the streamrn // with the appropriate error state.rn //rn // Notice the following two faults that should result in failurern // to read:rn // 1. The formula has a too small number of clausesrn // 2. The number of variables declared is differentrn // from the actual number of variables appearingrn // in the different clauses.rn friend std::istream& operator>>(std::istream&, Formula&);rnrnprivate:rn // Add your own data members and member functions.rn;rnrn// Write the toStringrnstd::ostream& operator<<(std::ostream&, const Formula&);rnrn#endif /* FORMULA_HPP_ */rn(未完)
跪求大神解答一下
在安装软件的时候出现“抽取:无法写入文件..”rn第二次安装就没事了rn请大神帮忙分析一下问题有可能出现在哪??
跪求解答啊
GetDlgItem(IDC_Sample)->GetWindowRect(&rect); rn ScreenToClient(&rect); rn InvalidateRect(rect,TRUE);rnInvalidateRect(rect,TRUE);rn我调用这些获得一个编辑框的坐标后,想重绘重新在编辑框中输出一些内容,在Onpaint中写rnCClientDC dc(GetDlgItem(IDC_Sample));rn rn // dc.TextOut(100,100+m_text1move,m_addtext1);rn GetDlgItem(IDC_Sample)->SetWindowText(m_addtext1);rn不能输出啊,Textout不能,但是用SetWindowText就能输出
java测试题 跪求解答!!
打印出如下图案(菱形) rn * rn *** rn ****** rn******** rn ****** rn *** rn * rn
MFC新手,跪求解答
我创建了一个IDD_calculate,并在IDR_MAINFRAME添加“计算器”菜单选项,想通过点击“计算器”实现打开计算器功能,请问里边的 command 消息处理函数怎么编写,最好有注释。
小弟跪求解答...
我有1000000条数据.用了 try rn Class.forName("oracle.jdbc.driver.OracleDriver");rn con=DriverManager.getConnection("jdbc:oracle:thin:@192.168.0.21:1521:oradb","market","market");rn rn Statement st = con.createStatement();rn for(int i=0;i<=1000000;i++)rn st.executeUpdate("insert into Authors values('"+i+"','中国人人')");rn rn catch (Exception e) rn e.printStackTrace();rn // TODO: handle exceptionrn rnSystem.out.print("dwad");rnrn rn这样太慢了,有没好的方法
跪求解答!!!在线等
我用FCKeditor在vs1.1版本里,现在是图片上传功能不能实现,不报错误的,希望有人能帮我解答一下,rnQQ116021166,在线等,rn跪谢了!!!
跪求解答 段错误!!
求教各位大神:rnsprintf(filename,"/home/panda/met/ag/netlongwave/%d.%d.%d.txt",year,month,day);rn if((Metfile = fopen(filename,"rt")) == NULL)rn fprintf(stderr,"could not open file %s\n",filename);rn exit(1);rn rn rn while(!feof(Metfile))rn fscanf(Metfile,"%f %f %f\n",&lat1, &lon1, &met1);rn lat[counter] = lat1;rn lon[counter] = lon1;rn met[counter] = met1;rn counter ++ ;rn rn fclose(Metfile);rn这段程序在运行时 出现段错误。 调试了下 计数器 counter会突然变成一个很大的负数。 这是什么问题,怎么解决?rn我的系统是 ubuntu linux 编译器是gcc
深夜等解答!跪求
具体题目是rn这是一公司的面试题学习之用下载研究,但水平低不太懂。C++ , VC++ 的书也看过好几大本了.一般的DLL应用知道 但下面这一行:rn bool dll_init(IBox * p_in/*IN*/, IController ** p_out/*OUT*/);rnrn内部怎么实现,跟界面按钮如何关联起来,实在搞不明白!请高手编写个简单的代码,每个按钮只响应一个提示也行,明白了思路后我自己再去仔细研究. (还请大家提供一些参考资料方便学习)rnrn 感谢!rnrn测试题:rn请编写一个dll,这个dll能与我们提供的exe(初试D.exe)工作,在exe的界面上绘制我们提供的图片test.jpg,并且,能够通过主界面的按钮上下左右的移动界面上的图片。rn提示:下面是我们的示例程序运行的效果图,你写的Dll中不需要写上“这是示例程序”那几个红色的文字。rn需要的借口在interface.h中有定义。rn示例程序是用vs2003编写。rn例子图片你可以转化为bmp后再使用。rn图片一次移动距离自己定,示例程序用的是5。rn注:请提供程序源代码rnrninterface.h文件rn #pragma oncerninterface IControllerrnrn virtual void draw(HWND wnd, RECT & rc) PURE;rn virtual void on_btn_up_pressed() PURE;rn virtual void on_btn_left_pressed() PURE;rn virtual void on_btn_right_pressed() PURE;rn virtual void on_btn_down_pressed() PURE;rn;rnrn//IBox接口由我们提供的exe实现,在调用你导出函数时,把IBox指针传给你rn//你需要实现IControllerrninterface IBox rnrn virtual HWND getWND() PURE;rn virtual RECT getDrawRect() PURE;rn;rn//dll提供的导出函数原型rntypedef bool (*dll_entry_type)(IBox * p_in/*IN*/, IController ** p_out/*OUT*/) ;rnextern "C" __declspec(dllexport) bool dll_init(IBox * p_in/*IN*/, IController ** p_out/*OUT*/);rnrn试题下载地址:www.tigou.net/downloads/cx.rarrnrnrnrnrn在说说我的情况,一切都完成的差不多了,就初始化图片的函数有问题,rn情况是这样的rninterface IBox rnrn virtual HWND getWND() PURE;rn virtual RECT getDrawRect() PURE;rn;rnrnrnvoid Controller::InitControl( IBox * p_in )rnrnthis->m_pBox = p_in;rnHINSTANCE hInstance = hInst;//就是这里如何得到模块实例的句柄,如何通过IBOX传来的信息知道呢???rnm_Bitmap = LoadBitmap(hInstance, (LPCWSTR)IDB_BITMAP);rn//还有这里是通过文件名来加载图片吗?比如LoadBitmap(hInstance, (LPCWSTR)IDB_BITMAP1);rn//图片资源已经加载进去,但是'IDB_BITMAP1' : undeclared identifierrn//哪里有什么问题求大神指导,感激不尽啊!!rnm_Sizecx = 0;rnm_Sizecy = 0;rnrn
跪求大神解答
现在有个项目,在APP上面提交资料,然后要在内网上面查看审核资料,内网映射端口到外网上,APP提交的资料通过外网的端口在把资料上传到服务器上行吗,小白一个跪求大神解答啊
跪求高手解答
我们会在网站上的 看到客服QQ。当我们点击的时候, 会从QQ自动弹出与该客服QQ的聊天窗口。请问,这是如何实现的?
AjaxPro问题,跪求解答...
小弟用AjaxPro做一个查看邮箱是否被注册过的程序,老是出错,百思不得其解,请各位大虾帮帮忙,不胜感激。。。rnrn错误提示:Microsoft JScript 运行时错误: 对象不支持此属性或方法rnrn运行环境:vs2008+sql server2005rnrnaspx页主要代码:rnrn <%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="ylsn.Web.Default" %>rnrnrnrn 理连结交友网rn rn rn rnrnrn rn 电子邮箱 rn rn rn rnrnrnrncs页主要代码:rnrn using System;rnusing System.Data;rnusing System.Configuration;rnusing System.Collections;rnusing System.Web;rnusing System.Web.Security;rnusing System.Web.UI;rnusing System.Web.UI.WebControls;rnusing System.Web.UI.WebControls.WebParts;rnusing System.Web.UI.HtmlControls;rnusing System.Collections.Generic;rnusing AjaxPro;rnrnrnnamespace ylsn.Webrnrn public partial class Default : System.Web.UI.Pagern rn protected void Page_Load(object sender, EventArgs e)rn rn if (!IsPostBack)rn rn AjaxPro.Utility.RegisterTypeForAjax(typeof(ylsn.Web.Default), this);rn rn rn public string CheckEmail(string email)rn rn string where = string.Format("email='0'",email);rn List UserModelList = new ylsn.BLL.tb_user().GetModelList(where);rn //如果没有记录就返回0,否则返回1rn if(UserModelList.Count==0)rn rn return "0";rn rn elsern rn return "1";rn rn rn rn
内联汇编跪求解答
输入字符串,转化大小写。rnrn原代码是这样的:rn#include rnint main()rnrnchar string[128];rngets(string);rnrn_asm rnjmp entryrnrnisletter1:rncmp al, 'a'rnjl nexrncmp al, 'z'rnjg nexrnmov ecx, 1rnretrnrnisletter2:rncmp al, 'A'rnjl nexrncmp al, 'Z'rnjg nexrnmov ecx, 1rnretrnrnnex:rnmov ecx, 0rnretrnrnentry:rnlea edx, stringrnrnloopStart:rnmov al, byte ptr ds:[edx]rntest al, alrnjz endrncall isletter1rntest ecx, ecxrnjz test2rnsub byte ptr ds:[edx], 'a'-'A'rnjmp nextCharrnrntest2:rncall isletter2rntest ecx, ecxrnjz nextCharrnadd byte ptr ds:[edx], 'a'-'A'rn rnnextChar:rninc edxrnjmp loopStartrnend:rn rnrnputs(string);rnreturn 0;rnrnrn可以运行,但是我需要用汇编语言读数,并且后期要循环方便输入多个字符串。rn所以我改了下,把gets()函数写进_asm :rn#include rnint main()rnrnchar string[128];rnchar format[] = "%s";rnrn_asmrnrnlea eax,string ;rnpush eax ;rnlea eax,format ;rnpush eax ;rncall scanf_s ;rnadd esp,8 ;rnrnjmp entryrnrnisletter1:rncmp al, 'a'rnjl nexrncmp al, 'z'rnjg nexrnmov ecx, 1rnretrnrnisletter2:rncmp al, 'A'rnjl nexrncmp al, 'Z'rnjg nexrnmov ecx, 1rnretrnrnnex:rnmov ecx, 0rnretrnrnentry:rnlea edx, stringrnrnloopStart:rnmov al, byte ptr ds:[edx]rntest al, alrnjz endrncall isletter1rntest ecx, ecxrnjz test2rnsub byte ptr ds:[edx], 'a'-'A'rnjmp nextCharrnrntest2:rncall isletter2rntest ecx, ecxrnjz nextCharrnadd byte ptr ds:[edx], 'a'-'A'rn rnnextChar:rninc edxrnjmp loopStartrnend:rnlea eax,string;rnpush eax;rncall printf;rnadd esp,4;rnrnreturn 0;rnrnrn为什么这样就不能打印结果了。。该怎么改。。坐等。。跪谢!
SQL问题 跪求解答
[img=http://www.53taobao.com/e/566a4a3b68a861a77db1e5e54b1b1d3c.jpg][/img]rn[img=https://forum.csdn.net/PointForum/ui/scripts/csdn/Plugin/001/face/2.gif][/img][img=https://forum.csdn.net/PointForum/ui/scripts/csdn/Plugin/003/monkey/0.gif][/img][img=https://forum.csdn.net/PointForum/ui/scripts/csdn/Plugin/003/onion/3.gif][/img]
内存问题,小弟跪求解答!!!
程序运行是弹出std::bad_alloc异常;rn兄弟们,给个办法吧,烦死了!rn代码如下,rn#include rn#include rn#include rn#include rnusing namespace std;rnrn#define FIleMaxNum 127 rn#define MaxValue 65530rnrn///////////////////////////////////////////////////rn//FileData:rnrnchar FileElemC[FIleMaxNum];rnint FileElemP[FIleMaxNum];rnstring FileRepElemStr[FIleMaxNum];rnrnrnrn//Haffman Data:rntypedef structrn int weight;rn int parent;rn int lchild;rn int rchild;rn int flags;rnHaffStruct;rnrnrn///////////////////////////////////////////////////rnrnbool Compress(string strPath) // 压缩rnrn /////////////////////////////////////////rn //Data Of Function;rn int FileCount;rn int HtreeCount;rn string FIleName = "e:\\read.txt"; //测试数据->路径2010.12.20;rn //FIleName = Path;rn string FileTempName = FileTempName + ".temp";rn /////////////////////////////////////////rn //Code of Functionrn ifstream rf;rn rf.open(FIleName.c_str());rn if (!rf)rn rn cout << "Rf不能打开!\n";rn return false;rn rn char c;rn int tag = 0;rn // 扫描获取File信息rn while( !rf.eof())rn rn rf.get(c);rn for (int x = 0; x < FileCount; x++)rn rn if (c == FileElemC[x])rn rn tag = 1;rn FileElemP[x] += 1;rn rn break;rn rn if (FileCount >= 2 && x < FileCount - 1 && FileElemP[x] < FileElemP[x + 1] )rn rn char ctemp = FileElemC[x];rn long ltemp = FileElemP[x];rnrn FileElemP[x] = FileElemP[x + 1];rn FileElemC[x] = FileElemC[x + 1];rn FileElemP[x + 1] = ltemp;rn FileElemC[x + 1] = ctemp;rn rnrn rn if (tag != 1)rn rn FileElemC[FileCount] = c;rn FileElemP[FileCount] += 1;rn rn FileCount++;rnrn rn tag = 0;rn rn rn rf.close();rn rn rn //-------------------------------------------------------rn //Haffman Code:rn HtreeCount = 2 * FileCount - 1;rn rn rn HaffStruct *Htree = (HaffStruct *)malloc(sizeof(HaffStruct) * HtreeCount);rn //FileStruct *fData = (FileStruct *)malloc(sizeof(FileStruct) * FileCount);rn //HaffStuct Htree[255];rn /* Haffman Init() */rn for (int x = 0; x < HtreeCount;x++)rn rn if (x < FileCount)rn rn Htree[x].weight = FileElemP[x];rn rn elsern rn Htree[x].weight = 0;rn rn /* end of init Htree[].weight */rn Htree[x].parent = -1;rn Htree[x].flags = 0;rn Htree[x].lchild = -1;rn Htree[x].rchild = -1;rn /* end of othes Elem */rn rnrn rn /* 构造haffman 的其他的非叶子节点 */rn int m1,m2; rn int x1,x2;rn rn for (int x = 0; x < FileCount - 1; x ++)rn rn m1 = m2 = MaxValue;rn x1 = x2 = 0;rn for (int y = 0; y < FileCount + x; y ++)rn rn if (Htree[y].weight < m1 && Htree[y].flags == 0)rn rn m2 = m1;rn x2 = x1;rn m1 = Htree[x].weight;rn x1 = y;rn rn else if (Htree[y].weight < m2 && Htree[y].flags == 0)rn rn m2 = Htree[y].weight;rn x2 = y;rn rn rn /* 查找两个最小子树结束 */rnrn /* 合并子树beg */rn Htree[x1].flags= 1;rn Htree[x2].flags = 1;rn Htree[x1].parent = FileCount + x;rn Htree[x2].parent = FileCount + x;rn Htree[FileCount + x].weight = Htree[x1].weight + Htree[x2].weight;rn Htree[FileCount + x].lchild = x1;rn Htree[FileCount + x].rchild = x2;rnrn rn rnrn /* 记录码字 */rn rn int _child,_parent;rn for (int x = 0; x < FileCount; x++)rn rn _child = x;rn _parent = Htree[_child].parent;rnrn while(_parent != -1)rn rn if (Htree[_parent].lchild == _child)rn rn FileRepElemStr[x].insert(0,1,'0');rn /**rn int _i = fData[x].flagsbit;rn fData[x].bit[_i] = 0;rn fData[x].flagsbit++;rn /**/rn rn elsern rn FileRepElemStr[x].insert(0,1,'1');rn /**rn int _i = fData[x].flagsbit;rn fData[x].bit[_i] = 0;rn fData[x].flagsbit++;rn */rn rn _child = _parent;rn _parent = Htree[_child].parent;rn rn rn rn rn rn rn ofstream wTempfile;rn wTempfile.open(FileTempName.c_str());rn ifstream rfile;rn rfile.open(FIleName.c_str());rn rn rfile.seekg(0,ios::beg);rn while( !rfile.eof())rn rn rf.get(c);rn for (int x = 0; x < FileCount; x++)rn rn if (FileElemC[x] == c)rn rn wTempfile << FileRepElemStr[x];rn rn break;rn rn rn long len_TempTxt = wTempfile.tellp();rn rfile.close();rn wTempfile.close();rnrn ///////////////////////////////////////////////rn //TEST CODE OF FUNCTION rn rn for (int x = 0; x < FileCount; x++)rn rn cout << FileElemC[x] << " " << FileElemP[x] << " "<< FileRepElemStr[x] << endl;rn rn /**/rn rn
相关热词 c# 线程结束时执行 c# kb mb 图片 c# 替换第几位字符 c#项目决定成败 c# 与matlab c# xml缩进 c#传感器基础 c#操作wps c# md5使用方法 c# 引用父窗口的组件