问题列表 - 第37991页

将视频转换为 mjpeg 文件格式

我有一个 java 程序来流式传输 mjpeg 文件。我无法在任何地方找到 mjpeg 文件。谁能帮助我如何获取文件。或者告诉我如何将文件转换为 mjpeg 格式?我曾尝试使用总视频转换器将 avi 文件转换为 mjpeg,但没有奏效。

video-streaming

3
推荐指数
1
解决办法
6075
查看次数

在测试阶段生成html surefire测试html输出

我不确定这是否是一个简单的问题,但我想在测试阶段确保生成html格式的输出文件(除了xml和txt格式的输出文件).

我试图通过为build> surefire添加一个'executions'条目来实现这一点.这是正确的位置吗?如果是这样,我做错了吗?

<build>
  ..
  <plugins>
    ..
    <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-surefire-report-plugin</artifactId>
                <version>2.6</version>
                <configuration>
                    <outputDirectory>site</outputDirectory>

                </configuration>
                <executions>
                    <execution>
                        <id>during-tests</id>
                        <phase>test</phase>
                        <goals>
                            <goal>report</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin> 
Run Code Online (Sandbox Code Playgroud)

maven-2 surefire

14
推荐指数
1
解决办法
3万
查看次数

回滚sql server中的所有记录

我的采访者问我问我在数据库表中插入10行,在第5行我发现有些麻烦然后我怎么能回滚所有记录?

请让我知道我该怎么做

sql sql-server sql-server-2005

1
推荐指数
1
解决办法
65
查看次数

在存储过程中,最好是简单地查询数据或构造查询然后执行它?为什么?

我已经研究过SQL存储过程,我注意到很多人使用两种不同的方法 -

首先,使用选择查询,例如

Select * from TableA where colA = 10 order by colA
Run Code Online (Sandbox Code Playgroud)

其次,是通过构建查询来做同样的事情

Declare @sqlstring varchar(100)
Declare @sqlwhereclause varchar(100)
Declare @sqlorderby varchar(100)

Set @sqlstring = 'Select * from TableA '
Set @sqlwhereclause = 'where colA = 10 '
Set @sqlorderby = 'order by colA'

Set @sqlstring = @sqlstring + @sqlwhereclause + @sqlorderby 
exec @sqlstring
Run Code Online (Sandbox Code Playgroud)

现在,我知道两者都很好.但是,我提到的第二种方法是维护有点烦人.

我想知道哪一个更好?是否有任何具体原因可以采用一种方法而不是另一种方法?一种方法比其他方法有什么好处?

sql sql-server stored-procedures

2
推荐指数
1
解决办法
117
查看次数

是否有可能从javax.naming.InitialContext获得"一切"?

是否可以从中检索"所有"(所有名称)javax.naming.InitialContext?我没有找到任何关于它的例子或文档.

java jndi

6
推荐指数
1
解决办法
4013
查看次数

红宝石的目的或文件是什么?

我在这里阅读了"Ruby编程语言"一书中的文档,并且不明白这里文档的目的是什么,以及何时将它用于生产代码.如果有人可以解释并提供一些使用示例,我会很高兴.

问候,

ruby heredoc

4
推荐指数
1
解决办法
320
查看次数

excel数组列double/triple/etc.辅音代

我如何为AA-ZZ等自动生成数组(在PHP中),如AAA-ZZZ

$column_arr2= range("aa", "zz"); // NOT Working
$row_arr    = range(0,1000);
$column_arr = range("a", "z");

echo "Column2<pre>".print_r($column_arr2, true)."</pre><br />"; // prints a - z
echo "Row<pre>".print_r($row_arr, true)."</pre><br />";
echo "Column<pre>".print_r($column_arr, true)."</pre><br />";
Run Code Online (Sandbox Code Playgroud)

想要使数字和alpha数组动态,因为我将它用于excel文档.

我想要的是:

$arr = ([0] => 'a', [1] => 'b', [2] => 'c', ...
        [26] => 'aa', [27] => 'ab', [28] => 'ac', ...
        [52] => 'ba', [53] => 'bb', [54] => 'bc', ...
       )
Run Code Online (Sandbox Code Playgroud)

欢迎任何想法

php arrays excel

3
推荐指数
1
解决办法
2332
查看次数

关于const限定符和构造函数的问题

这是一个简单的程序.如果我评论构造函数,我得到一个错误只是想检查这是什么原因?

t.cc: In function 'int main(int, char**)':                                                                                                                              
t.cc:26: error: uninitialized const 'const_test'


#include <iostream>                                                                                                                                                     

using namespace std;                                                                                                                                                    

class TestPrint                                                                                                                                                         
{                                                                                                                                                                       
public:                                                                                                                                                                 
  //  TestPrint() {}                                                                                                                                                    
  void Print()                                                                                                                                                          
  {                                                                                                                                                                     
    std::cout << "TestPrint" << std::endl;                                                                                                                              
  }                                                                                                                                                                     

  void Print() const                                                                                                                                                    
  {                                                                                                                                                                     
    std::cout << "const TestPrint" << std::endl;                                                                                                                        
  }                                                                                                                                                                     
};                                                                                                                                                                      


int main(int argc, char* argv[])                                                                                                                                        
{                                                                                                                                                                       
  TestPrint normal_test;                                                                                                                                                
  normal_test.Print();                                                                                                                                                  

  const TestPrint const_test;                                                                                                                                           
  const_test.Print();                                                                                                                                                   
}                                                                                                                             
Run Code Online (Sandbox Code Playgroud)

c++ constructor const

2
推荐指数
1
解决办法
334
查看次数

全屏运行C++控制台程序

如何全屏运行C++控制台程序?,使用VS2008

c++ visual-c++

6
推荐指数
3
解决办法
2万
查看次数

在页面加载时将光标更改为忙碌

我理解如何使用javascript在页面制作和ajax调用时将光标更改为busy.

但是我有一个不使用ajax的页面,它使用回发来重新加载页面.然而,负载相当数据密集,需要几秒钟.在此期间,用户仍然可以单击该页面.我想将光标变为"等待",因此用户不会尝试单击该页面.

例如,我有几个导致回发的下拉列表.我做了一个选择,页面加载3秒钟.当它加载时我希望光标转向等待,这样用户就不会尝试在第二个下拉列表中进行选择,直到页面重新加载.

这可能吗?

附加信息:(我的设置的简化版)

我有一个主页:

<form id="form1" runat="server">
<table width = "100%" bgcolor="White">
<tr><td>
<h3><asp:ContentPlaceHolder id="MAIN" runat="server"></asp:ContentPlaceHolder></h3>
</tr></td>
</table>
</form>
<script type="text/javascript">
    function cursorwait(e) {
        document.body.style.cursor = 'wait';
    }

    var fm = document.getElementById('<% =form1.ClientID %>');
    if (fm.addEventListener) {
        fm.addEventListener('submit', cursorwait, false);
    }
    else {
        fm.attachEvent('onsubmit', cursorwait);
    }
</script>
Run Code Online (Sandbox Code Playgroud)

然后是使用母版页的页面:

<asp:Content ID="Content1" ContentPlaceHolderID="MAIN" Runat="Server">
<table runat=server id="tb_simple_search_table" cellpadding = 0 cellspacing = 0>
<tr><td>
    <asp:DropDownList...
    <asp:DropDownList...
</td></tr>
</table>
</asp:content>
Run Code Online (Sandbox Code Playgroud)

javascript asp.net postback cursor

8
推荐指数
2
解决办法
3万
查看次数