To implement the intent service,
there are a number of steps that
you're going to need to follow.
The first thing to do is to create
a GeoFenceTransitionsIntentService
class and have this extend
the IntentService base class.
You'll then need to add a constructor
and add an onCreate override to this.
Generally these will be empty, but
in the constructor you could call super
tag, and in the onCreate you could just
pass onCreate up to super as well.
Finally, you'll need to create
an override for onHandleIntent.
Now this takes an intent as
a parameter and returns void.
Once you've created all this stub code,
check this box when you're done.
لتنفيذ خدمة التعليمة الهدف،
هناك عدد من الخطوات التي
ستحتاج إلى اتباعها.
أول شيء يجب أن تقوم به هو إنشاء طبقة
GeoFenceTransitionsIntentService
وجعل هذا الإجراء يعمل على توسيع
طبقة IntentService الأساسية.
ستحتاج بعد ذلك إلى إضافة دالة إنشائية
وإضافة تجاوز onCreate إليها.
ستكون فارغة بشكل عام، ولكن
يمكنك أن تطلب وضع علامة
ويمكنك في onCreate تمرير
onCreate up إلى العلامة أيضًا.
وأخيرًا، ستحتاج إلى إنشاء
تجاوز لـ onHandleIntent.
ويأخذ هذا المعلمة الهدف
كمعلمة وترجع بقيمة فارغة.
بمجرد إنشاء تعليمة هذا المكعب،
تحقق من هذه الخانة عند الانتهاء.
Para implementar o Intent Service,
há várias etapas
que você precisará seguir.
A primeira coisa a fazer é criar
uma classe GeoFenceTransitionsIntentService,
e ela vai ampliar
a classe base IntentService.
Você precisará adicionar um Constructor
e uma substituição onCreate a ela.
Geralmente estarão vazios,
mas no Constructor você pode chamar
uma super tag, e no onCreate
você pode apenas
passar onCreate para a super também.
Finalmente, você precisará criar
uma substituição para onHandleIntent.
Ela pega um Intent
como um parâmetro e retorna nulo.
Depois de criar todo esse resto de código,
marque essa caixa de seleção.
要实现 intent 服务
我们需要遵循一些步骤
首先是创建一个 GeoFenceTransitionsIntentService 类
将其扩展到 IntentService 基础类
然后需要添加一个构造函数 并向其添加一个 onCreate 重写
一般来说 这些将是空的 但是在构造函数中你可以调用 Super(TAG)
在 onCreate 中 也可以只向 Super 传递 onCreate
最后 还需要为 onHandleIntent 创建一个重写
现在这需要一个 Intent 作为参数并返回空
如果已经创建所有此存根代码 完成后请选中此方框