[#36686] 1.1 < 61.1 - 60.0 — Shin-ichiro HARA <sinara@...>

原です。

19 messages 2002/12/06

[#36770] www.ruby-lang.orgリニューアル準備のお知らせ — TADA Tadashi <sho@...>

ruby-lang.orgのwebmasterチームでは、タイムリーな情報提供と使いやすい

11 messages 2002/12/16

[ruby-list:36680] Re: WIN32OLE とIAgentCtlRequest

From: arton <artonx@...>
Date: 2002-12-05 14:13:30 UTC
List: ruby-list #36680
artonです。

On Thu, 5 Dec 2002 22:42:35 +0900
nobu.nakada@nifty.ne.jpさん wrote:

> IDプロパティというのがWIN32OLE汎用のものならこんなとこで。
> 
> class WIN32OLE
>   def ==(other)
>     self.ID == other.ID
>   end
> end
> 
あぁ、なるほど。しかし、汎用ではないので(普通は、ItemとかValueというプ
ロパティ名になります)、次のほうが良いと思います。

class WIN32OLE
  def ==(other)
    if WIN32OLE === other
        return _invoke(0,[],[]) == other.invoke(0,[],[])
    end
    super(other)
  end
end

-- 
arton <artonx@yahoo.co.jp>

__________________________________________________
Do You Yahoo!?
Yahoo! BB is Broadband by Yahoo!  http://bb.yahoo.co.jp/


In This Thread