走过海棠暮

文章 0 评论 0 浏览 24

走过海棠暮 2024-11-30 20:27:00

我注意到这个问题主要发生在我安装了 nuget 包之后。添加nuget包后我发现我无法签出。重新启动 Visual Studio 会有所帮助。

基于此讨论:

http://nuget.codeplex.com/discussions/254328

我使用了这个似乎有效的解决方案:
(如果网页消失,我已将解决方案复制到此处)

Control Panel / Internet Options / Security Tab
Select "Local Intranet"
Click Sites button
Click Advanced Button
Add your TFS server http address to the list. e.g. http://tfs
Restart Visual Studio

来源:http://blog.rthand.com/post/2011/08/26/Fishing-combination-of-NuGet-and-Team-Foundation-in-workgroup-configuration-401-Unauthorized.aspx< /a> (直接转到解决方案 的一半)。

不要让“Internet 选项”部分欺骗了您。我不使用 Internet Explorer,这解决了我的问题。

I noticed that the problem occurred mostly after i installed a nuget package. After adding a nuget package i found that I could not check out. Restarting Visual Studio helped.

Based on this discussion:

http://nuget.codeplex.com/discussions/254328

i used this solution which appears to be working:
(I have copied the solution here if ever the webpage disappears)

Control Panel / Internet Options / Security Tab
Select "Local Intranet"
Click Sites button
Click Advanced Button
Add your TFS server http address to the list. e.g. http://tfs
Restart Visual Studio

Source: http://blog.rthand.com/post/2011/08/26/Fixing-combination-of-NuGet-and-Team-Foundation-in-workgroup-configuration-401-Unauthorized.aspx (Go straight down to The Solution half way down).

Don't let the Internet Options part fool you. I do not use Internet Explorer and this solved my issue.

TF30063: 您无权访问集合。 Nuget 和 Tfs 冲突

走过海棠暮 2024-11-30 19:22:54

它正在寻找不存在的文件,
如果解决方案中缺少您的诡计,它将不允许构建。

这是解决方案中的问题,认为文件存在,如果您通过 Windows 资源管理器查看文件应该所在的位置,则它不再存在。所以它试图复制不存在的文件..

希望这有帮助

--误读

文件上的右键。
选择选项构建操作并选择内容
复制到输出目录 选择始终复制(这将确保将文件复制到目录中)

发布,文件应该在那里

,您应该准备好开始:)

It is looking for file that does not exists,
if your wile is missing in solution it will not allow to build.

this is problem in solution thinking that file is exists and if you look via windows explorer to location where the file is supossed to be, it is not there anymore. So it is trying to copy nonexisting file ..

Hope this helps

--misread

right button on the file.
select option build action and select content
copy to output directory select copy always (this will ensure coping the file into the directory)

publish and the file should be there

and you should be ready to go:)

在 Visual Studio 2010 上发布网站失败 (MVC3)

走过海棠暮 2024-11-27 00:42:02

如果您不以 -A 开头,即使 CLI 也可能调用 SHOW TABLES。

Even the CLI may call SHOW TABLES if you don't start it with -A.

mysql 可以自动触发 SHOW TABLES 吗?

走过海棠暮 2024-11-26 22:59:14

Boost Geometry 库 昨天发布,有一个实现<代码>凸包算法。一张图片表达了一千多个单词:

在此处输入图像描述

尽管这构建了一个“新的” ' 非凹形(即凸形)的形状;这可能是也可能不是您想要的。然而,在此过程中,算法必然能够对凹/凸形状进行分类,因此您可能仍然对该库感兴趣。

有关凸包算法的一般信息:


由于 Adrian Japon 或多或少地建议“命中测试”(遏制测试)是关心凸/凹几何形状的常见原因,而无需话不多说,我将重点介绍相应的 Boost Geometry 算法:

再说一遍,真的是因为图片太漂亮了。请注意,虽然图片建议查询多边形上的点,但这些算法是完全通用的,可用于测试另一个n多边形的完全包含子>

在此处输入图像描述

The Boost Geometry library that was published yesterday, has an implementation of Convex Hull algorithm. A picture says more than a thousand words:

enter image description here

Although this constructs a 'new' shape that is non-concave (i.e. convex); This may or may not be precisely what you want. However, in the process the algorithm is bound to be able to classify shape a concave/convex, so you'd likely be interested in the library nonetheless.

General information on convex hull algorithm:


Since Adrian Japon more or less suggested that 'hit testing' (containment test) is of a usual reason to care about convex/concave geometries, without further ado, I'll highlight the corresponding Boost Geometry algorithm for that: within.

Again, really because the picture is so pretty. Note that though the picture suggests querying for a point against a polygon, the algorithms are fully generic and can be used to test complete containment on n-dimensional polygons in another

enter image description here

如何用凸形状形成凹形状?

走过海棠暮 2024-11-26 22:08:52

请参阅 http://code.google.com/p/shelves/ Google Shleves 项目实际上正在做你想做的事。请参阅他们维护对图像的弱引用和软引用的代码。

Please see http://code.google.com/p/shelves/ Google Shleves project they are actually doing what you want. please see code they are maintaining WeakReference and SoftReference to Images.

在 Android 上序列化 Drawable 对象

走过海棠暮 2024-11-26 20:49:43

此规则会将所有对 http://site.com/somepage.html 的请求重定向(301 永久重定向)到 http://www.site.com/somepage.html > (如果域名 = site.com 则有效):

<system.webServer>
    <rewrite>
        <rules>
            <rule name="Force www" stopProcessing="true">
                <match url="(.*)" />
                <conditions>
                    <add input="{HTTP_HOST}" pattern="^site\.com$" />
                </conditions>
                <action type="Redirect" url="http://www.site.com/{R:1}" />
            </rule>
        </rules>
    </rewrite>
</system.webServer>

此域名将执行相同的操作,但会从任何子域重定向到 www(例如 hello.site.com => www.site .com):

<system.webServer>
    <rewrite>
        <rules>
            <rule name="Force www" stopProcessing="true">
                <match url="(.*)" />
                <conditions>
                    <add input="{HTTP_HOST}" pattern="^www\.site\.com$" negate="true" />
                </conditions>
                <action type="Redirect" url="http://www.site.com/{R:1}" />
            </rule>
        </rules>
    </rewrite>
</system.webServer>

注意:

  1. 您需要存在 URL 重写 v2 模块(也应该与 v1.x 一起使用,但我无法测试它 - 只能使用 v2)。

  2. (显然)您的网站应该接受那些非 www 子域。

  3. 此规则需要放置在网站 root 文件夹中的 web.config 中。

This rule will redirect (301 Permanent Redirect) all requests to http://site.com/somepage.html into http://www.site.com/somepage.html (will work if domain name = site.com):

<system.webServer>
    <rewrite>
        <rules>
            <rule name="Force www" stopProcessing="true">
                <match url="(.*)" />
                <conditions>
                    <add input="{HTTP_HOST}" pattern="^site\.com$" />
                </conditions>
                <action type="Redirect" url="http://www.site.com/{R:1}" />
            </rule>
        </rules>
    </rewrite>
</system.webServer>

This one will do the same but will redirect from ANY SUBDOMAIN to www (e.g. hello.site.com => www.site.com):

<system.webServer>
    <rewrite>
        <rules>
            <rule name="Force www" stopProcessing="true">
                <match url="(.*)" />
                <conditions>
                    <add input="{HTTP_HOST}" pattern="^www\.site\.com$" negate="true" />
                </conditions>
                <action type="Redirect" url="http://www.site.com/{R:1}" />
            </rule>
        </rules>
    </rewrite>
</system.webServer>

NOTES:

  1. You will need URL Rewrite v2 module to be present (should work with v1.x as well, but I cannot test it -- only v2 around).

  2. (Obviously) your site should accept those non-www subdomains.

  3. This rule need to be placed in web.config in website root folder.

在 IIS 7 中重定向网站的最佳方法

走过海棠暮 2024-11-26 17:13:37

您确定仅在您的应用程序中使用 inproc 识别器吗?您可以通过在应用程序中实例化 SpeechRecognitionEngine() 来实现此目的。请参阅SpeechRecognitionEngine 类。我怀疑您正在实例化共享识别器 - 语音识别器类

Are you sure you are using an inproc recognizer for your application only. You do this by instantiating a SpeechRecognitionEngine() in your application. See SpeechRecognitionEngine Class. I suspect you are instantiating a shared recognizer - SpeechRecognizer Class

使用 System.Speech.Recognition 打开 Windows 语音识别

走过海棠暮 2024-11-26 16:35:09

我在使用大型解决方案时遇到了完全相同的问题。尝试一下这个插件,解决方案负载管理器,它可以让您本质上,您的解决方案中的项目是“延迟加载”项目,因此您只有那些在开放和消耗内存中积极工作的项目。

为我创造了奇迹。

I was having the exact same problem working with large solutions. Give this plugin a try, Solution Load Manager, it lets you essentially "lazy load" projects in your solution, so you only have the ones you're actively working in open and consuming memory.

Worked wonders for me.

Visual Studio 2010内存消耗

走过海棠暮 2024-11-26 16:19:10

如果您有字符串之类的对象,那么您可以使用 JSON.parse() 函数。

var stringCal = "{
        header: {
            left: 'prev,next today',
            center: 'title',
            right: 'month,agendaWeek,agendaDay'
        },
        editable: true,
    }";

然后

$('#calendar').fullCalendar(JSON.parse(stringCal));

If you have the object like a string then you can use the JSON.parse() function.

var stringCal = "{
        header: {
            left: 'prev,next today',
            center: 'title',
            right: 'month,agendaWeek,agendaDay'
        },
        editable: true,
    }";

then

$('#calendar').fullCalendar(JSON.parse(stringCal));

FullCalendar 与字符串的使用

走过海棠暮 2024-11-26 15:47:46

这几乎是为了清楚起见。

虽然将浮点数乘以整数可能会导致性能下降(将整数转换为浮点数),但这取决于编译器,并且也不应该是一个足够大的损失来担心(除非你正在做很多事情) 这样的操作)。

然而,它的清晰度绝对值得加分。最后,您实际上是将一个浮点数乘以一个浮点数,并且没有理由隐藏这个事实。如果 ax 是浮点值,则让它们为浮点值。

It's pretty much for clarity.

While multiplying a float by an integer may incur a small performance hit (for converting the integer to a float), this depends on the compiler and also shouldn't be a large enough penalty to worry about (unless you are doing many such operations).

However, it definitely scores points for clarity. In the end, you really are multiplying a floating-point number by a floating-point number, and there is no reason to hide this fact. If a and x are meant to be float values, let them be float values.

使用“x*=-1”的优点。超过“x *= -1”?

走过海棠暮 2024-11-26 15:13:55

媒体播放器是一个完整的应用程序。整个应用程序不存在“设计模式”这样的东西。

然而,某些软件系列(例如视频游戏)几乎总是共享一些共同的架构属性。但我们现在处于应用程序架构级别,而不是设计模式级别,设计模式通常被视为代码级别概念。

恐怕没有针对媒体播放器类型的应用程序的参考架构,但是,您可以依赖许多不同且不太具体的架构原则。例如,设计复合应用程序是一种非常普遍的做法。您会发现很多关于如何创建可以加载模块或编解码器等的插件系统的专门文献。

A media player is a whole application. There is no such thing as a "design pattern" for an entire application.

However, some families of softwares (say, video games) almost always share some common architectural properties. But we are at the application architecture level here, not at the design pattern one, which is commonly considered as a code level concept.

I'm afraid there is no reference architecture for a media player kind of application, but yet, you can rely on many different and less specific architectural principles. For example, designing a composite application is quite a general practice. You'll find a lot of dedicated literature about how to create a plugin system that can load module, or codec, etc.

玩家设计模式

走过海棠暮 2024-11-26 15:12:44

您在示例代码中命名的 seckey64 实际上是来自 CMS 的 SignedData 结构

它包含两个“签名属性”,签名时间和消息摘要。为了将其验证为签名,您需要遵循在至少存在一个签名属性时适用的 RFC 规则。

在您的情况下,原始数据的消息摘要包含在消息摘要属性中,因此您需要首先将您的计算与属性的每个字节的值字节进行比较。

如果它们相等,则您可以从 SignerInfo 结构的相应字段中提取签名值。最后,作为 DSA 签名验证的其他输入的 SHA-1 消息摘要将通过 SignerInfo 签名属性的原始编码进行计算。我不确定 M2Crypto 是否内置对 SignedData 的支持(它仍然经常被称为 PKCS#7),但我猜 pyOpenSSL 应该支持它,所以如果 M2Crypto 把你引向死胡同,你可以尝试一下。

What you named seckey64 in your sample code is actually a SignedData structure from CMS.

It contains two "signed attributes", signing-time and message-digest. In order to verify this as a signature you need to follow the rules of the RFC that apply when at least one signed attribute is present.

In your case the message digest of the original data is contained in the message-digest attribute, so you would need to compare your computation with the attribute's value byte per byte first.

If these are equal, then you'd extract the signature value from the appropriate field of the SignerInfo structure. Finally your SHA-1 message digest that serves as the other input to the DSA signature verification will be computed over the raw encoding of the signed attributes of the SignerInfo. I'm not sure if M2Crypto has built-in support for SignedData (it's still often referred to as PKCS#7), but I guess pyOpenSSL should support it, so you could give it a try if M2Crypto leads you to a dead end.

无法根据 m2crypto 中的 DSA 公钥验证 dsawithSha1 签名消息

走过海棠暮 2024-11-26 11:57:37

您可以使用 AS3GIF 并创建您自己的“循环进度”动画 GIF。

例如,如果您的动画 GIF 有 20 帧,您可以在每 5% 的步长调用函数 GIFPlayer.gotoAndStop(pFrame: int)

You could use AS3GIF and create your own "circular progress" animated GIF.

If, for example, your animated GIF has 20 frames, you can call the function GIFPlayer.gotoAndStop(pFrame: int) at each 5% step.

Flex 3 - 如何制作圆形进度条?

走过海棠暮 2024-11-26 04:05:13

恐怕这是不可能的,但是从类中读取属性的代码将知道它正在从哪个类中读取。因此,无论您需要对该类名做什么,都应该在那里完成。

That's not possible, I'm afraid, but the code that reads the attribute from the class will know which class it is reading from. So whatever you need to do with that class name should be done there.

如何获取我的类属性设置的类的类型?

走过海棠暮 2024-11-26 01:29:15

在这里聚会已经太晚了,但是如果你有一个 kwargs 函数:

def foo(a=None, b=None):
    ...

并且你像这样泼洒 dict

d_1 = { 'a': 1, 'b': 2 }
d_2 = dict(a=1, b=2)

# This works
foo(**d_1)

# And this as well
foo(**d_2)

但是 d_2 可能更适合重构可能会改变的参数名称在您的 foo 签名中。因为在 d_1 中它们是字符串。

Super late to the party here, but if you have a kwargs function:

def foo(a=None, b=None):
    ...

And your splatting a dict like so:

d_1 = { 'a': 1, 'b': 2 }
d_2 = dict(a=1, b=2)

# This works
foo(**d_1)

# And this as well
foo(**d_2)

But d_2 may be better suited for refactoring argument names that may change in your foo signature. Since in d_1 they are strings.

使用字典文字和字典构造函数之间有区别吗?

更多

推荐作者

浪漫人生路

文章 0 评论 0

620vip

文章 0 评论 0

羞稚

文章 0 评论 0

走过海棠暮

文章 0 评论 0

你好刘可爱

文章 0 评论 0

陌若浮生

文章 0 评论 0

    我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
    原文