2017-02-20 17 views
0

なぜそれが言われますか文字列、EXTRA_STREAMがURIの場合は、AndroidドキュメントのWebサイトにあります。私はアンドロイドのドキュメントを読む方法を理解しようとしています。Intent.EXTRA_STREAM in Android

EXTRA_STREAM

ストリング EXTRA_STREAM

コンテンツ:URIは、送信されるデータを供給するためにACTION_SENDと共に使用意図、関連付けられたデータのストリームを保持します。

public void composeEmail(String[] addresses, String subject, Uri attachment) { 
    Intent intent = new Intent(Intent.ACTION_SEND); 
    intent.setType("*/*"); 
    intent.putExtra(Intent.EXTRA_EMAIL, addresses); 
    intent.putExtra(Intent.EXTRA_SUBJECT, subject); 
    intent.putExtra(Intent.EXTRA_STREAM, attachment); 
    if (intent.resolveActivity(getPackageManager()) != null) { 
     startActivity(intent); 
    } 
} 

答えて

0

StringはConstant Intent.EXTRA_STREAMの型です。追加の名前はすべてStringでなければなりません。

0

情報技術では、ユニフォームリソース識別子は、文字列の文字を使用してリソースを識別します。