コード例 #1
0
        static public PartitionTransferSyntax Load(IPersistenceContext read, ServerEntityKey key)
        {
            var broker = read.GetBroker <IPartitionTransferSyntaxEntityBroker>();
            PartitionTransferSyntax theObject = broker.Load(key);

            return(theObject);
        }
コード例 #2
0
 static public PartitionTransferSyntax Insert(PartitionTransferSyntax entity)
 {
     using (var update = PersistentStoreRegistry.GetDefaultStore().OpenUpdateContext(UpdateContextSyncMode.Flush))
     {
         PartitionTransferSyntax newEntity = Insert(update, entity);
         update.Commit();
         return(newEntity);
     }
 }
コード例 #3
0
        static public PartitionTransferSyntax Insert(IUpdateContext update, PartitionTransferSyntax entity)
        {
            var broker        = update.GetBroker <IPartitionTransferSyntaxEntityBroker>();
            var updateColumns = new PartitionTransferSyntaxUpdateColumns();

            updateColumns.ServerPartitionKey      = entity.ServerPartitionKey;
            updateColumns.ServerTransferSyntaxKey = entity.ServerTransferSyntaxKey;
            updateColumns.Enabled = entity.Enabled;
            PartitionTransferSyntax newEntity = broker.Insert(updateColumns);

            return(newEntity);
        }