What is the translation of " MỘT SINGLETON " in English?

Examples of using Một singleton in Vietnamese and their translations into English

{-}
  • Colloquial category close
  • Ecclesiastic category close
  • Computer category close
Đó là một singleton.
Thật hiếm khi bạn cần một singleton.
It's rare that you need a singleton.
Chúng ta build một singleton như sau.
We can implement a Singleton as follows.
Tuy nhiên lúc này MyClass không còn là một singleton nữa.
The class is no more singleton.
Trong ví dụ này, lớp kết nối cơ sở dữ liệu hoạt động như một Singleton.
In this example, the database connection class acts as a Singleton.
Bạn cần một singleton.
It's rare that you need a singleton.
Nó sẽ chobạn thấy làm thế nào để xây dựng một singleton.
It will show you how to construct a singleton.
Chúng ta có thể implement một Singleton như sau.
We can implement a Singleton as follows.
Đầu tiên, chúng ta sẽ thay đổi DataModel thành một singleton.
First we are going to make the server class a singleton.
Khi bạn tạo ra một singleton, thì ta cũng phải đụng tới class.
When you create a singleton, you also need to create a shared instance of the class.
Chúng ta sẽ inject nó như một Singleton Object.
We will treat it as a singleton.
Thuật ngữ này xuấtphát từ khái niệm toán học của một singleton.
The term came from the mathematical concept of a singleton.
Bởi vì sau đó, bạn không có" chính xác một singleton" trong ứng dụng của bạn nữa.
Because then, you do not have"exactly one singleton" in your application anymore.
Xem mã dưới đây;nó sẽ cho bạn thấy làm thế nào để xây dựng một singleton.
Look at the code below- it will show you how to construct a singleton.
Khi bạn tạo một singleton, bạn cũng cần phải tạo một đối tượng để chia sẻ trong lớp.
When you create a singleton, you also need to create a shared instance of the class.
Tất nhiên đây là một ví dụ về một cách sử dụng xấu của một singleton.
Of course this is an example of a bad usage of a singleton.
Tôi không thể nghĩ vềmột tình huống đơn lẻ mà một singleton là giải pháp đúng đắn.
I can't personally think of a single situation where a singleton is the right solution.
Một cách để nghĩ về điều này là service locator là mộtđăng ký không phải là một singleton.
A way to think of this is thatservice locator is a registry not a singleton.
Vì vậy, lập luận của bạn là có hiệu quả" khôngcó hại trong việc tạo ra một singleton nếu chúng ta không đãi nó như một singleton.
So your argument is effectively"there's no harm in making a singleton if we don't treat it as a singleton.
Do các dịch vụ cung cấp bởi các đối tượng gốc như vậy là phổ biến,nó thường được thực hiện như một Singleton.
Because the service provided by the factory object is so pervasive,it is routinely implemented as a Singleton.
Chúng ta đã tạo ra một static inner class nắm giữ instance của một Singleton class.
Notice the private inner static class that contains the instance of the singleton class.
Một singleton cung cấp một cách đơn giản để thực hiện một đăng ký, nhưng mà quyết định thực hiện có thể dễ dàng thay đổi.
A singleton provides a simple way of implementing a registry, but that implementation decision is easily changed.
Và nếu bạn không có ý định truy cập nó như thế,thì có ít lý do để làm cho nó thành một singleton ngay từ đầu.
And if you don't intend to access it like that,then there's little reason to make it a singleton in the first place.
Một singletonmột class chỉ cho phép một instance riêng của nó được tạo ra và cho phép truy cập vào instance được tạo ra đó.
A singleton is a class that allows only a single instance of itself to be created and gives access to that created instance.
Không có lý do gì mà một cổng nối tiếp đơn lẻ trên một bo mạch phát triển nênđược mô hình hóa như một Singleton.
There's no reason that a single serial port on adevelopment board should be modeled as a Singleton.
Vì vậy, bạn chắc chắn rằng chỉ có một singleton trong ứng dụng của bạn tồn tại và tất cả các cơ sở dữ liệu đi qua này và chỉ SingletonDao.
So you are sure that only one singleton in your application exists and all database go through this one and only SingletonDao.
Heh, nếu bạn làm điều này ở khắp mọi nơi, sau đó bạn sẽ phải vượt qua một tham chiếu đến singelton ở khắp mọi nơi cũng có,và do đó bạn không có một singleton nữa.
Heh, if you do this everywhere, then you would have to pass around a reference to the singelton everywhere also,and thus you don't have a singleton any more.
Một singleton có thể được khởi tạomột cách lười biếng hoặc không đồng bộ trong khi một lớp tĩnh thường được khởi tạo khi nó được nạp lần đầu tiên, dẫn đến các vấn đề về trình nạp lớp tiềm năng.
A singleton can be initialized lazily or asynchronously while a static class is generally initialized when it is first loaded, leading to potential class loader issues.
Mimpen: Không, một Singleton vốn- S( đó là những gì đang được thảo luận ở đây) là một thể hiện của một lớp học mà( a) đảm bảo rằng chỉ có một cá thể sẽ tồn tại, và( b) được truy cập thông qua điểm truy cập toàn cục được tích hợp sẵn của lớp.
Mimpen: No, a capital-S Singleton(which is what is being discussed here) is an instance of a class that(a) guarantees that only one instance will ever exist, and(b) is accessed via the class's own built-in global point of access.
Kotlin có một cách để xác định singleton một cách rất thông minh.
Kotlin has a feature to define a singleton in a very clever way.
Results: 161, Time: 0.016

Word-for-word translation

Top dictionary queries

Vietnamese - English