Difference between revisions of "Zh/Documentation/DevGuide/WritingUNO/C++/Implementing your own Interfaces"

From Apache OpenOffice Wiki
Jump to: navigation, search
m (New page: {{Documentation/DevGuide/WritingUNOTOC/Zh |WritingUNO2d=block |ShowPrevNext=block |PrevPage=Zh/Documentation/DevGuide/WritingUNO/C++/Class Definition with Helper Template Classes |NextPage...)
 
m
 
Line 10: Line 10:
 
对于 <code>my_module.XSomething</code> 接口,添加一个当成功调用 methodOne() 时用于通知调用程序的返回字符串。
 
对于 <code>my_module.XSomething</code> 接口,添加一个当成功调用 methodOne() 时用于通知调用程序的返回字符串。
  
For the <code>my_module.XSomething</code> interface, add a string to be returned that informs the caller when <code>methodOne()</code> was called successfully.
 
 
<!--[SOURCE:Components/CppComponent/service2_impl.cxx]-->
 
<!--[SOURCE:Components/CppComponent/service2_impl.cxx]-->
 
<source lang="cpp">
 
<source lang="cpp">

Latest revision as of 05:32, 30 July 2008


对于 my_module.XSomething 接口,添加一个当成功调用 methodOne() 时用于通知调用程序的返回字符串。

  OUString MyService2Impl::methodOne( OUString const & str )
      throw (RuntimeException)
  {
      return OUString( RTL_CONSTASCII_USTRINGPARAM(
          "called methodOne() of MyService2 implementation: ") ) + str;
  }
Content on this page is licensed under the Public Documentation License (PDL).
Personal tools
In other languages