returns the LockEntry for the Writer of object obj.
If now writer exists, null is returned.
964849
public LockEntry getWriter(Object obj)
    {
        PersistenceBroker broker = getBroker();
        Identity oid = new Identity(obj, broker); 
        return getWriter(oid);
    }
18087
function isWritable(obj, key) {
  var descriptor = Object.getOwnPropertyDescriptor(obj, key);
  return isUndefined(obj[key]) || descriptor && descriptor.writable
}
479175
public void removeWriter(LockEntry writer)
    {
        checkTimedOutLocks();

        String oidString = writer.getOidString();
        ObjectLocks objectLocks = null;
        synchronized (locktable)
        {
        	objectLocks = (ObjectLocks) locktable.get(oidString);
        }
        if (objectLocks == null)
        {
            return;
        }
        else
        {
			/**
        	 * MBAIRD, last one out, close the door and turn off the lights.
        	 * if no locks (readers or writers) exist for this object, let's remove
        	 * it from the locktable.
        	 */
        	synchronized (locktable)
        	{
        		Map readers = objectLocks.getReaders();
        		objectLocks.setWriter(null);
        		// no need to check if writer is null, we just set it.
            	if (readers.size() == 0)
            	{
            		locktable.remove(oidString);
            	}
        	}
        }
    }
843
protected void writeObject(Object o)
	{
		if (o == null)
		{
			return;
		}
		getPersistenceDelegate(o.getClass()).writeObject(o, this);
	}
1174783
public static Writer getInstance(Writer out) {
		// Already in Unix format, no conversion necessary
		if(UNIX_EOL.equals(EOL)) return out;
		// Use FindReplaceWriter
		return new FindReplaceWriter(out, EOL, UNIX_EOL);
	}
629708
IWriter buildWriter(final IClassContainer classContainer) {
        try {
            return new BufferedFileWriter(classContainer.getExportClassName(), path, format.getExtension());
        } catch (IOException e) {
            logger.warning(e.getMessage());
            return null;
        }
    }
411936
public T getObject(String key) {
        if (this.objects.containsKey(key)) {
            return this.objects.get(key);
        }
        return null;
    }
879582
@SuppressWarnings("unchecked")
	public void addWriter(RecordWriter<SerializationDelegate<T>> writer)
	{
		// avoid using the array-list here to reduce one level of object indirection
		if (this.writers == null) {
			this.writers = new RecordWriter[] {writer};
		}
		else {
			RecordWriter<SerializationDelegate<T>>[] ws = new RecordWriter[this.writers.length + 1];
			System.arraycopy(this.writers, 0, ws, 0, this.writers.length);
			ws[this.writers.length] = writer;
			this.writers = ws;
		}
	}
856731
public Object get(String descriptor, String[] actualReturn) {
        if (descriptor == null) {
            throw new NullPointerException("descriptor must not be null");
        }
        return getKey(createKey(descriptor), actualReturn);
    }
328158
private File getWriteLock() {
        File[] lckFiles = this.lockPath.listFiles(lockFilter);
        for (final File lckFile : lckFiles) {
            if (lockFilter.isWriterLockFile(lckFile)) {
                return lckFile;
            }
        }

        return null;
    }
128549
def Serialize(self, writer):
        
        super(StorageItem, self).Serialize(writer)
        writer.WriteVarBytes(self.Value)
315961
function (obj) {
        "use strict";

        if (Object.getPrototypeOf(obj) !== Object.prototype) {
            throw Error("obj must be an Object");
        }

        return Object.keys(obj)[0] || null;
    }
743089
function getWriter(input) {
  const writer = input.getWriter();
  const releaseLock = writer.releaseLock;
  writer.releaseLock = () => {
    writer.closed.catch(function() {});
    releaseLock.call(writer);
  };
  return writer;
}
648744
def value(self):
        
        if self._wrapped is not self.Null:
            return self._wrapped
        else:
            return self.obj
1107528
public boolean checkWrite(TransactionImpl tx, Object obj)
    {
        LockEntry writer = getWriter(obj);
        if (writer == null)
            return false;
        else if (writer.isOwnedBy(tx))
            return true;
        else
            return false;
    }
518527
def get_storage(obj):
    
    annotation = IAnnotations(obj)
    if annotation.get(SNAPSHOT_STORAGE) is None:
        annotation[SNAPSHOT_STORAGE] = PersistentList()
    return annotation[SNAPSHOT_STORAGE]
953971
public boolean readLock(TransactionImpl tx, Object obj)
    {

        LockEntry writer = getWriter(obj);
        if (writer == null)
        {
            addReader(tx, obj);
            // if there has been a successful write locking, try again
            if (getWriter(obj) == null)
                return true;
            else
            {
                removeReader(tx, obj);
                return readLock(tx, obj);
            }
        }
        if (writer.isOwnedBy(tx))
        {
            return true;    // If I'm the writer, I can read.
        }
        else
        {
            return false;
        }
    }